Message ID | 20250418064008.7172-1-quic_lingbok@quicinc.com |
---|---|
State | New |
Headers | show |
Series | [ath-next,v3] wifi: ath12k: Abort scan before removing link interface to prevent duplicate deletion | expand |
diff --git a/drivers/net/wireless/ath/ath12k/mac.c b/drivers/net/wireless/ath/ath12k/mac.c index d170bca72948..fca004e8564b 100644 --- a/drivers/net/wireless/ath/ath12k/mac.c +++ b/drivers/net/wireless/ath/ath12k/mac.c @@ -9846,6 +9846,11 @@ ath12k_mac_op_unassign_vif_chanctx(struct ieee80211_hw *hw, reinit_completion(&ar->completed_11d_scan); ar->state_11d = ATH12K_11D_PREPARING; } + + if (ar->scan.arvif == arvif && ar->scan.state == ATH12K_SCAN_RUNNING) { + ath12k_scan_abort(ar); + ar->scan.arvif = NULL; + } } static int