wifi: ath12k: add WoW net-detect functionality
authorBaochen Qiang <quic_bqiang@quicinc.com>
Tue, 4 Jun 2024 05:54:03 +0000 (13:54 +0800)
committerKalle Valo <quic_kvalo@quicinc.com>
Mon, 24 Jun 2024 16:31:46 +0000 (19:31 +0300)
commit16f474d6d49db5d93e79c2d4bdcc3a730cf1d1f1
tree8ece6b74008437e33d02d0f6e94c05bb6e8456a8
parent4a3c212eee0e36c1cd55bfbfb94041a0d3ad265b
wifi: ath12k: add WoW net-detect functionality

Implement net-detect feature by setting flag
WIPHY_WOWLAN_NET_DETECT if firmware supports this
feature. Driver sets the related PNO configuration
to firmware before entering WoW and firmware then
scans periodically and wakes up host if a specific
SSID is found.

Note that firmware crashes if we enable it for both
P2P vdev and station vdev simultaneously because
firmware can only support one vdev at a time. Since
there is rare scenario for a P2P vdev to do net-detect,
skip it for P2P vdevs.

Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0-03427-QCAHMTSWPL_V1.0_V2.0_SILICONZ-1.15378.4

Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://patch.msgid.link/20240604055407.12506-5-quic_bqiang@quicinc.com
drivers/net/wireless/ath/ath12k/core.h
drivers/net/wireless/ath/ath12k/mac.c
drivers/net/wireless/ath/ath12k/wmi.c
drivers/net/wireless/ath/ath12k/wmi.h
drivers/net/wireless/ath/ath12k/wow.c