wifi: ath11k: move power type check to ASSOC stage when connecting to 6 GHz AP
authorBaochen Qiang <quic_bqiang@quicinc.com>
Tue, 21 May 2024 08:08:11 +0000 (11:08 +0300)
committerKalle Valo <quic_kvalo@quicinc.com>
Thu, 23 May 2024 12:45:52 +0000 (15:45 +0300)
commit6e16782d6b4a724f9c9dcd49471219643593b60c
tree6a8272503536846c24f978e6a13f2c3385df6332
parented281c6ab6eb8a914f06c74dfeaebde15b34a3f4
wifi: ath11k: move power type check to ASSOC stage when connecting to 6 GHz AP

With commit bc8a0fac8677 ("wifi: mac80211: don't set bss_conf in parsing")
ath11k fails to connect to 6 GHz AP.

This is because currently ath11k checks AP's power type in
ath11k_mac_op_assign_vif_chanctx() which would be called in AUTH stage.
However with above commit power type is not available until ASSOC stage.
As a result power type check fails and therefore connection fails.

Fix this by moving power type check to ASSOC stage, also move regulatory
rules update there because it depends on power type.

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

Fixes: bc8a0fac8677 ("wifi: mac80211: don't set bss_conf in parsing")
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://msgid.link/20240424064019.4847-1-quic_bqiang@quicinc.com
drivers/net/wireless/ath/ath11k/mac.c