Message ID | 20230717034457.22162-1-quic_wgong@quicinc.com (mailing list archive) |
---|---|
State | Accepted |
Commit | 9632ea57be659887ab0d28a2a1d7b901dfddd263 |
Delegated to: | Kalle Valo |
Headers | show |
Series | wifi: ath12k: add handler for scan event WMI_SCAN_EVENT_DEQUEUED | expand |
Wen Gong <quic_wgong@quicinc.com> wrote: > When wlan interface is up, and 11d scan is sent to the firmware, then > firmware needs to spend couple of seconds to complete the 11d scan. If > normal scan from user space arrives to ath12k at this moment, then the > normal scan request is also sent to the firmware, but the scan started > event will be reported to ath12k until the 11d scan complete. When timed > out for the scan started in ath12k, ath12k stops the normal scan and the > firmware reports WMI_SCAN_EVENT_DEQUEUED to ath12k for the normal scan. > ath12k has no handler for the event and then timed out for the scan > completed in ath12k_scan_stop(), and ath12k prints the following error > message. > > [ 1491.604750] ath12k_pci 0000:02:00.0: failed to receive scan abort comple: timed out > [ 1491.604756] ath12k_pci 0000:02:00.0: failed to stop scan: -110 > [ 1491.604758] ath12k_pci 0000:02:00.0: failed to start hw scan: -110 > > Add a handler for WMI_SCAN_EVENT_DEQUEUED and then complete the scan to > get rid of the above error message. > > Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4 > > Signed-off-by: Wen Gong <quic_wgong@quicinc.com> > Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com> Patch applied to ath-next branch of ath.git, thanks. 9632ea57be65 wifi: ath12k: add handler for scan event WMI_SCAN_EVENT_DEQUEUED
diff --git a/drivers/net/wireless/ath/ath12k/wmi.c b/drivers/net/wireless/ath/ath12k/wmi.c index 7ae0bb78b2b5..8329c1bcbb36 100644 --- a/drivers/net/wireless/ath/ath12k/wmi.c +++ b/drivers/net/wireless/ath/ath12k/wmi.c @@ -5688,6 +5688,8 @@ static void ath12k_scan_event(struct ath12k_base *ab, struct sk_buff *skb) ath12k_wmi_event_scan_start_failed(ar); break; case WMI_SCAN_EVENT_DEQUEUED: + __ath12k_mac_scan_finish(ar); + break; case WMI_SCAN_EVENT_PREEMPTED: case WMI_SCAN_EVENT_RESTARTED: case WMI_SCAN_EVENT_FOREIGN_CHAN_EXIT:
When wlan interface is up, and 11d scan is sent to the firmware, then firmware needs to spend couple of seconds to complete the 11d scan. If normal scan from user space arrives to ath12k at this moment, then the normal scan request is also sent to the firmware, but the scan started event will be reported to ath12k until the 11d scan complete. When timed out for the scan started in ath12k, ath12k stops the normal scan and the firmware reports WMI_SCAN_EVENT_DEQUEUED to ath12k for the normal scan. ath12k has no handler for the event and then timed out for the scan completed in ath12k_scan_stop(), and ath12k prints the following error message. [ 1491.604750] ath12k_pci 0000:02:00.0: failed to receive scan abort comple: timed out [ 1491.604756] ath12k_pci 0000:02:00.0: failed to stop scan: -110 [ 1491.604758] ath12k_pci 0000:02:00.0: failed to start hw scan: -110 Add a handler for WMI_SCAN_EVENT_DEQUEUED and then complete the scan to get rid of the above error message. Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4 Signed-off-by: Wen Gong <quic_wgong@quicinc.com> --- drivers/net/wireless/ath/ath12k/wmi.c | 2 ++ 1 file changed, 2 insertions(+) base-commit: 0a00db612b6df1fad80485e3642529d1f28ea084