linux/drivers/net/wireless/ath/ath11k
Wen Gong bb300130e4 ath11k: reduce the wait time of 11d scan and hw scan while add interface
(cherry picked from commit 1f682dc9fb in wireless-next)

Currently ath11k will wait 11d scan complete while add interface in
ath11k_mac_op_add_interface(), when system resume without enable
wowlan, ath11k_mac_op_add_interface() is called for each resume, thus
it increase the resume time of system. And ath11k_mac_op_hw_scan()
after ath11k_mac_op_add_interface() also needs some time cost because
the previous 11d scan need more than 5 seconds when 6 GHz is enabled,
then the scan started event will indicated to ath11k after the 11d
scan completed.

While 11d scan/hw scan is running in firmware, if ath11k update channel
list to firmware by WMI_SCAN_CHAN_LIST_CMDID, then firmware will cancel
the current scan which is running, it lead the scan failed. The patch
commit 9dcf6808b2 ("ath11k: add 11d scan offload support") used
finish_11d_scan/finish_11d_ch_list/pending_11d to synchronize the 11d
scan/hw scan/channel list between ath11k/firmware/mac80211 and to avoid
the scan fail.

Add wait operation before ath11k update channel list, function
ath11k_reg_update_chan_list() will wait until the current 11d scan/hw
scan completed. And remove the wait operation of start 11d scan and
waiting channel list complete in hw scan. After these changes, resume
time cost reduce about 5 seconds and also hw scan time cost reduced
obviously, and scan failed not seen.

The 11d scan is sent to firmware only one time for each interface added
in mac.c, and it is moved after the 1st hw scan because 11d scan will
cost some time and thus leads the AP scan result update to UI delay.
Currently priority of ath11k's hw scan is WMI_SCAN_PRIORITY_LOW, and
priority of 11d scan in firmware is WMI_SCAN_PRIORITY_MEDIUM, then the
11d scan which sent after hw scan will cancel the hw scan in firmware,
so change the priority to WMI_SCAN_PRIORITY_MEDIUM for the hw scan which
is in front of the 11d scan, thus it will not happen scan cancel in
firmware.

Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3

Fixes: 9dcf6808b2 ("ath11k: add 11d scan offload support")
Link: https://bugzilla.kernel.org/show_bug.cgi?id=215777
Cc: <stable@vger.kernel.org>
Signed-off-by: Wen Gong <quic_wgong@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20220328035832.14122-1-quic_wgong@quicinc.com
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20220427111619.9758-1-kvalo@kernel.org
2022-04-29 09:00:28 +03:00
..
ahb.c ath11k: fix kernel panic during unload/load ath11k modules 2022-01-31 15:59:05 +02:00
ahb.h ath11k: Remove rproc references from common core layer 2020-09-21 16:11:28 +03:00
ce.c ath11k: Disabling credit flow for WMI path 2021-11-17 09:28:04 +02:00
ce.h ath11k: Replace zero-length arrays with flexible-array members 2022-02-21 12:24:34 +02:00
core.c ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
core.h ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
dbring.c ath11k: add dbring debug support 2022-02-24 11:02:48 +02:00
dbring.h ath11k: add spectral/CFR buffer validation support 2021-12-09 10:14:20 +02:00
debug.c ath11k: add trace log support 2021-11-17 09:29:34 +02:00
debug.h ath11k: add trace log support 2021-11-17 09:29:34 +02:00
debugfs_htt_stats.c ath11k: add HTT stats support for new stats 2021-09-28 16:53:15 +03:00
debugfs_htt_stats.h ath11k: add HTT stats support for new stats 2021-09-28 16:53:15 +03:00
debugfs_sta.c ath11k: report tx bitrate for iw wlan station dump 2021-12-20 20:29:01 +02:00
debugfs_sta.h ath11k: report tx bitrate for iw wlan station dump 2021-12-20 20:29:01 +02:00
debugfs.c ath11k: add dbring debug support 2022-02-24 11:02:48 +02:00
debugfs.h ath11k: add dbring debug support 2022-02-24 11:02:48 +02:00
dp_rx.c ath11k: translate HE status to radiotap format 2022-02-24 10:59:41 +02:00
dp_rx.h ath11k: Clear the fragment cache during key install 2021-05-11 20:16:21 +02:00
dp_tx.c Merge ath-next from git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git 2022-02-25 11:36:57 +02:00
dp_tx.h ath11k: report tx bitrate for iw wlan station dump 2021-12-20 20:29:01 +02:00
dp.c ath11k: Process full monitor mode rx support 2021-12-09 10:10:33 +02:00
dp.h ath11k: Replace zero-length arrays with flexible-array members 2022-02-21 12:24:34 +02:00
hal_desc.h ath11k: decode HE status tlv 2022-02-24 10:59:20 +02:00
hal_rx.c ath11k: translate HE status to radiotap format 2022-02-24 10:59:41 +02:00
hal_rx.h ath11k: decode HE status tlv 2022-02-24 10:59:20 +02:00
hal_tx.c ath11k: add data path support for QCN9074 2021-02-17 11:32:51 +02:00
hal_tx.h ath11k: add hal support for QCN9074 2021-02-17 11:32:48 +02:00
hal.c ath11k: Avoid false DEADLOCK warning reported by lockdep 2021-12-13 11:49:22 +02:00
hal.h ath11k: Avoid false DEADLOCK warning reported by lockdep 2021-12-13 11:49:22 +02:00
hif.h ath11k: add CE interrupt support for QCN9074 2021-02-17 11:32:58 +02:00
htc.c ath11k: Disabling credit flow for WMI path 2021-11-17 09:28:04 +02:00
htc.h ath11k: Disabling credit flow for WMI path 2021-11-17 09:28:04 +02:00
hw.c ath11k: Fix missing rx_desc_get_ldpc_support in wcn6855_ops 2022-01-31 16:06:01 +02:00
hw.h ath11k: add dbring debug support 2022-02-24 11:02:48 +02:00
Kconfig
mac.c ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
mac.h ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
Makefile ath11k: implement WoW enable and wakeup commands 2020-12-12 06:41:37 +02:00
mhi.c ath11k: configure RDDM size to mhi for recovery by firmware 2022-02-21 12:05:41 +02:00
mhi.h ath11k: mhi: hook suspend and resume 2020-12-12 06:41:16 +02:00
pci.c ath11k: pci: fix crash on suspend if board file is not found 2022-01-31 16:11:47 +02:00
pci.h ath11k: refactor multiple MSI vector implementation 2021-11-22 13:11:02 +02:00
peer.c ath11k: Refactor the fallback routine when peer create fails 2022-01-11 16:39:15 +02:00
peer.h ath11k: fix fw crash due to peer get authorized before key install 2021-11-15 11:14:58 +02:00
qmi.c ath11k: Handle failure in qmi firmware ready 2022-02-21 12:28:17 +02:00
qmi.h ath11k: add ath11k_qmi_free_resource() for recovery 2022-02-21 12:04:59 +02:00
reg.c ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
reg.h ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
rx_desc.h ath11k: Replace zero-length arrays with flexible-array members 2022-02-21 12:24:34 +02:00
spectral.c ath11k: Replace zero-length arrays with flexible-array members 2022-02-21 12:24:34 +02:00
spectral.h
testmode_i.h
testmode.c ath11k: remove repeated words in comments and warnings 2020-10-28 15:44:04 +02:00
testmode.h
thermal.c
thermal.h
trace.c ath11k: add trace log support 2021-11-17 09:29:34 +02:00
trace.h ath11k: add support of firmware logging for WCN6855 2021-12-22 08:03:13 +02:00
wmi.c ath11k: reduce the wait time of 11d scan and hw scan while add interface 2022-04-29 09:00:28 +03:00
wmi.h ath11k: add WMI calls to manually add/del/pause/resume TWT dialogs 2022-02-01 12:57:07 +02:00
wow.c ath11k: implement WoW enable and wakeup commands 2020-12-12 06:41:37 +02:00
wow.h ath11k: implement WoW enable and wakeup commands 2020-12-12 06:41:37 +02:00