Unverified Commit 535bd9e3 authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!12147 wifi: iwlwifi: mvm: don't wait for tx queues if firmware is dead

parents 793da324 5eec8647
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -5574,6 +5574,10 @@ static void iwl_mvm_flush_no_vif(struct iwl_mvm *mvm, u32 queues, bool drop)
	int i;

	if (!iwl_mvm_has_new_tx_api(mvm)) {
		/* we can't ask the firmware anything if it is dead */
		if (test_bit(IWL_MVM_STATUS_HW_RESTART_REQUESTED,
			     &mvm->status))
			return;
		if (drop) {
			mutex_lock(&mvm->mutex);
			iwl_mvm_flush_tx_path(mvm,
@@ -5658,8 +5662,11 @@ void iwl_mvm_mac_flush(struct ieee80211_hw *hw, struct ieee80211_vif *vif,

	/* this can take a while, and we may need/want other operations
	 * to succeed while doing this, so do it without the mutex held
	 * If the firmware is dead, this can't work...
	 */
	if (!drop && !iwl_mvm_has_new_tx_api(mvm))
	if (!drop && !iwl_mvm_has_new_tx_api(mvm) &&
	    !test_bit(IWL_MVM_STATUS_HW_RESTART_REQUESTED,
		      &mvm->status))
		iwl_trans_wait_tx_queues_empty(mvm->trans, msk);
}