]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/blobdiff - drivers/net/wireless/iwlwifi/mvm/d3.c
iwlwifi: mvm: reserve sta_id 0 to station
[mirror_ubuntu-eoan-kernel.git] / drivers / net / wireless / iwlwifi / mvm / d3.c
index e3a9cec45566f94b7cda7b43231283320157d803..b956e2f0b631c4d3a50a3b89bd25dea6ac7351e1 100644 (file)
@@ -963,7 +963,6 @@ static int __iwl_mvm_suspend(struct ieee80211_hw *hw,
        };
        int ret, i;
        int len __maybe_unused;
-       u8 old_aux_sta_id, old_ap_sta_id = IWL_MVM_STATION_COUNT;
 
        if (!wowlan) {
                /*
@@ -980,8 +979,6 @@ static int __iwl_mvm_suspend(struct ieee80211_hw *hw,
 
        mutex_lock(&mvm->mutex);
 
-       old_aux_sta_id = mvm->aux_sta.sta_id;
-
        /* see if there's only a single BSS vif and it's associated */
        ieee80211_iterate_active_interfaces_atomic(
                mvm->hw, IEEE80211_IFACE_ITER_NORMAL,
@@ -1066,16 +1063,6 @@ static int __iwl_mvm_suspend(struct ieee80211_hw *hw,
 
        iwl_trans_stop_device(mvm->trans);
 
-       /*
-        * The D3 firmware still hardcodes the AP station ID for the
-        * BSS we're associated with as 0. Store the real STA ID here
-        * and assign 0. When we leave this function, we'll restore
-        * the original value for the resume code.
-        */
-       old_ap_sta_id = mvm_ap_sta->sta_id;
-       mvm_ap_sta->sta_id = 0;
-       mvmvif->ap_sta_id = 0;
-
        /*
         * Set the HW restart bit -- this is mostly true as we're
         * going to load new firmware and reprogram that, though
@@ -1096,16 +1083,6 @@ static int __iwl_mvm_suspend(struct ieee80211_hw *hw,
        mvm->ptk_ivlen = 0;
        mvm->ptk_icvlen = 0;
 
-       /*
-        * The D3 firmware still hardcodes the AP station ID for the
-        * BSS we're associated with as 0. As a result, we have to move
-        * the auxiliary station to ID 1 so the ID 0 remains free for
-        * the AP station for later.
-        * We set the sta_id to 1 here, and reset it to its previous
-        * value (that we stored above) later.
-        */
-       mvm->aux_sta.sta_id = 1;
-
        ret = iwl_mvm_load_d3_fw(mvm);
        if (ret)
                goto out;
@@ -1222,10 +1199,6 @@ static int __iwl_mvm_suspend(struct ieee80211_hw *hw,
 
        iwl_trans_d3_suspend(mvm->trans, test);
  out:
-       mvm->aux_sta.sta_id = old_aux_sta_id;
-       mvm_ap_sta->sta_id = old_ap_sta_id;
-       mvmvif->ap_sta_id = old_ap_sta_id;
-
        if (ret < 0)
                ieee80211_restart_hw(mvm->hw);
  out_noreset: