wifi: iwlwifi: mvm: protect TXQ list manipulation
authorJohannes Berg <johannes.berg@intel.com>
Fri, 17 Mar 2023 09:53:25 +0000 (10:53 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 20 Apr 2023 10:35:11 +0000 (12:35 +0200)
commit6c2103d9a88ed0c01e1abd9c100c273db1c03bf3
treea414fbd66a83c904135dded683fe6794a3d94738
parent742ae1a6c65df9e77149e3b4b9cc292a170b214a
wifi: iwlwifi: mvm: protect TXQ list manipulation

[ Upstream commit 923bf981eb6ecc027227716e30701bdcc1845fbf ]

Some recent upstream debugging uncovered the fact that in
iwlwifi, the TXQ list manipulation is racy.

Introduce a new state bit for when the TXQ is completely
ready and can be used without locking, and if that's not
set yet acquire the lock to check everything correctly.

Reviewed-by: Benjamin Berg <benjamin.berg@intel.com>
Tested-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/intel/iwlwifi/mvm/mac80211.c
drivers/net/wireless/intel/iwlwifi/mvm/mvm.h
drivers/net/wireless/intel/iwlwifi/mvm/ops.c
drivers/net/wireless/intel/iwlwifi/mvm/sta.c