wifi: ath12k: add wait operation for tx management packets for flush from mac80211
authorKarthik M <quic_karm@quicinc.com>
Fri, 28 Apr 2023 17:01:37 +0000 (20:01 +0300)
committerKalle Valo <quic_kvalo@quicinc.com>
Fri, 5 May 2023 12:56:02 +0000 (15:56 +0300)
commit5189a8dba849f0153f30561e3ac257e0be01abdd
tree90188003c252f9d2c92a5504a22634d5a1226da0
parente2ceb1de2f83aafd8003f0b72dfd4b7441e97d14
wifi: ath12k: add wait operation for tx management packets for flush from mac80211

Transmission of management packets are done in a work queue. Sometimes
the workqueue does not finish Tx immediately, then it lead after the next
step of vdev delete finished, it start to send the management packet to
firmware and lead firmware crash.

ieee80211_set_disassoc() have logic of ieee80211_flush_queues() after
it send_deauth_disassoc() to ath12k, its purpose is make sure the
deauth was actually sent, so it need to change ath12k to match the
purpose of mac80211.

To address these issues wait for Tx management as well as Tx data packets.

Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1

Signed-off-by: Karthik M <quic_karm@quicinc.com>
Signed-off-by: Ramya Gnanasekar <quic_rgnanase@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://lore.kernel.org/r/20230419095738.19859-1-quic_rgnanase@quicinc.com
drivers/net/wireless/ath/ath12k/core.c
drivers/net/wireless/ath/ath12k/core.h
drivers/net/wireless/ath/ath12k/mac.c
drivers/net/wireless/ath/ath12k/wmi.c