summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
diff options
context:
space:
mode:
authorLuca Coelho <luciano.coelho@intel.com>2018-02-27 16:37:56 +0200
committerLuca Coelho <luciano.coelho@intel.com>2018-08-31 11:38:18 +0300
commit11a0513cac8afb0c78280a10db72bcd671a8841f (patch)
tree0ff08175b6cb9b3e5c456d0aeadc9fcc622b2324 /drivers/net/wireless/intel/iwlwifi/mvm/d3.c
parent2d8c261511abfebd705d2163500d6b3049f0dec6 (diff)
downloadtalos-op-linux-11a0513cac8afb0c78280a10db72bcd671a8841f.tar.gz
talos-op-linux-11a0513cac8afb0c78280a10db72bcd671a8841f.zip
iwlwifi: mvm: remove duplicate if in iwl_mvm_setup_connection_keep()
We repeated the same if twice in a row. Remove the second one and move the code block into the previous one. Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Diffstat (limited to 'drivers/net/wireless/intel/iwlwifi/mvm/d3.c')
-rw-r--r--drivers/net/wireless/intel/iwlwifi/mvm/d3.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
index 47ceffbfd9af..799ee015ef84 100644
--- a/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
+++ b/drivers/net/wireless/intel/iwlwifi/mvm/d3.c
@@ -1503,6 +1503,7 @@ static bool iwl_mvm_setup_connection_keep(struct iwl_mvm *mvm,
.conf.cipher = gtkdata.cipher,
.conf.keyidx = status->gtk.key_index,
};
+ __be64 replay_ctr;
switch (gtkdata.cipher) {
case WLAN_CIPHER_SUITE_CCMP:
@@ -1524,11 +1525,9 @@ static bool iwl_mvm_setup_connection_keep(struct iwl_mvm *mvm,
if (IS_ERR(key))
return false;
iwl_mvm_set_key_rx_seq(mvm, key, status);
- }
- if (status->num_of_gtk_rekeys) {
- __be64 replay_ctr =
- cpu_to_be64(le64_to_cpu(status->replay_ctr));
+ replay_ctr = cpu_to_be64(le64_to_cpu(status->replay_ctr));
+
ieee80211_gtk_rekey_notify(vif, vif->bss_conf.bssid,
(void *)&replay_ctr, GFP_KERNEL);
}
OpenPOWER on IntegriCloud