iwlwifi: mvm: take station lock later in the code
authorSara Sharon <sara.sharon@intel.com>
Mon, 27 Aug 2018 10:56:41 +0000 (13:56 +0300)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 20 Dec 2018 07:08:04 +0000 (09:08 +0200)
There is no need to lock mvm station for transport reclaim.
Move the locking down, after the reclaim.

Signed-off-by: Sara Sharon <sara.sharon@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/intel/iwlwifi/mvm/tx.c

index 4ebfd41..995fe2a 100644 (file)
@@ -1817,8 +1817,6 @@ static void iwl_mvm_tx_reclaim(struct iwl_mvm *mvm, int sta_id, int tid,
                return;
        }
 
-       spin_lock_bh(&mvmsta->lock);
-
        __skb_queue_head_init(&reclaimed_skbs);
 
        /*
@@ -1828,6 +1826,8 @@ static void iwl_mvm_tx_reclaim(struct iwl_mvm *mvm, int sta_id, int tid,
         */
        iwl_trans_reclaim(mvm->trans, txq, index, &reclaimed_skbs);
 
+       spin_lock_bh(&mvmsta->lock);
+
        tid_data->next_reclaimed = index;
 
        iwl_mvm_check_ratid_empty(mvm, sta, tid);