Search Linux Wireless

Re: [PATCH] wifi: ath12k: avoid deadlock by change ieee80211_queue_work for regd_update_work

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Wen Gong <quic_wgong@xxxxxxxxxxx> wrote:

> Deadlock is easily happened while shutdown wlan interface such as run
> "ifconfig wlan0 down".
> 
> The reason is because when ar->regd_update_work is ran, it will
> call wiphy_lock(ar->hw->wiphy) in function ath12k_regd_update() which
> is running in workqueue of ieee80211_local queued by ieee80211_queue_work().
> Another thread from "ifconfig wlan0 down" will also accuqire the lock
> by wiphy_lock(sdata->local->hw.wiphy) in function ieee80211_stop(), and
> then it call ieee80211_stop_device() to flush_workqueue(local->workqueue),
> this will wait the workqueue of ieee80211_local finished. Then deadlock
> will happen easily if the two thread run meanwhile.
> 
> 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@xxxxxxxxxxx>
> Signed-off-by: Kalle Valo <quic_kvalo@xxxxxxxxxxx>

Patch applied to ath-next branch of ath.git, thanks.

8198950ccb7d wifi: ath12k: avoid deadlock by change ieee80211_queue_work for regd_update_work

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20230718024724.29120-1-quic_wgong@xxxxxxxxxxx/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux