wifi: iwlwifi: release TXQ lock during reclaim
authorBenjamin Berg <benjamin.berg@intel.com>
Wed, 3 Jul 2024 09:58:57 +0000 (12:58 +0300)
committerJohannes Berg <johannes.berg@intel.com>
Thu, 4 Jul 2024 11:50:05 +0000 (13:50 +0200)
commita2ed933dfefac8976ac915e1b1b60028b9c344b3
tree49137b67833e9257ebde5a3d1f3696a30535a99d
parent1a3364e963989dbcd1465dd8e94d9c5babd3474a
wifi: iwlwifi: release TXQ lock during reclaim

Much of the work during reclaim can be done without holding the TXQ
lock and releasing the lock means that command submission can happen at
the same time.

Add a new reclaim_lock to prevent parallel cleanup. Release the lock
while working with an internal copy of the txq->read_ptr and only take
the lock again when updating the read pointer after the cleanup is done.

Signed-off-by: Benjamin Berg <benjamin.berg@intel.com>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20240703125541.2a81021d49ac.I53698ae92fb75a0461d41176db115462cf8be1cd@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/iwl-trans.h
drivers/net/wireless/intel/iwlwifi/pcie/tx-gen2.c
drivers/net/wireless/intel/iwlwifi/pcie/tx.c