]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
LinuxKPI: 802.11 fix locking in lkpi_stop_hw_scan()
authorBjoern A. Zeeb <bz@FreeBSD.org>
Mon, 10 Jan 2022 22:12:53 +0000 (22:12 +0000)
committerBjoern A. Zeeb <bz@FreeBSD.org>
Mon, 10 Jan 2022 22:29:23 +0000 (22:29 +0000)
commitbec766282f242aab3a4bfba402ea74cb0ccf96fb
treed113b7a6733979a949a660dda77161f01f97fbed
parentd0ff9b029c7175e20c801126be127db7c651b02e
LinuxKPI: 802.11 fix locking in lkpi_stop_hw_scan()

In lkpi_stop_hw_scan() we have to unlock around cancelling the
hardware scan and an msleep to wait for the confirmation that the
scan ended.  Otherwise we are sleeping with the non-sleepable
net80211 com lock held.  At the same time we need to hold the lhw
lock for the msleep().
This lock change got lost in the refactoring of lkpi_iv_newstate().

Reported by: ambrisko, delphij
PR: 261075
MFC after: 3 days
Sponsored by: The FreeBSD Foundation
sys/compat/linuxkpi/common/src/linux_80211.c