diff options
Diffstat (limited to 'drivers/net/wireless/ath/ath5k/reset.c')
-rw-r--r-- | drivers/net/wireless/ath/ath5k/reset.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/net/wireless/ath/ath5k/reset.c b/drivers/net/wireless/ath/ath5k/reset.c index 7297d7b7704..e360e73b326 100644 --- a/drivers/net/wireless/ath/ath5k/reset.c +++ b/drivers/net/wireless/ath/ath5k/reset.c | |||
@@ -1020,13 +1020,12 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1020 | struct ieee80211_channel *channel, bool fast, bool skip_pcu) | 1020 | struct ieee80211_channel *channel, bool fast, bool skip_pcu) |
1021 | { | 1021 | { |
1022 | u32 s_seq[10], s_led[3], tsf_up, tsf_lo; | 1022 | u32 s_seq[10], s_led[3], tsf_up, tsf_lo; |
1023 | u8 mode, freq, ee_mode; | 1023 | u8 mode, ee_mode; |
1024 | int i, ret; | 1024 | int i, ret; |
1025 | 1025 | ||
1026 | ee_mode = 0; | 1026 | ee_mode = 0; |
1027 | tsf_up = 0; | 1027 | tsf_up = 0; |
1028 | tsf_lo = 0; | 1028 | tsf_lo = 0; |
1029 | freq = 0; | ||
1030 | mode = 0; | 1029 | mode = 0; |
1031 | 1030 | ||
1032 | /* | 1031 | /* |
@@ -1071,7 +1070,6 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1071 | switch (channel->hw_value & CHANNEL_MODES) { | 1070 | switch (channel->hw_value & CHANNEL_MODES) { |
1072 | case CHANNEL_A: | 1071 | case CHANNEL_A: |
1073 | mode = AR5K_MODE_11A; | 1072 | mode = AR5K_MODE_11A; |
1074 | freq = AR5K_INI_RFGAIN_5GHZ; | ||
1075 | ee_mode = AR5K_EEPROM_MODE_11A; | 1073 | ee_mode = AR5K_EEPROM_MODE_11A; |
1076 | break; | 1074 | break; |
1077 | case CHANNEL_G: | 1075 | case CHANNEL_G: |
@@ -1083,7 +1081,6 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1083 | } | 1081 | } |
1084 | 1082 | ||
1085 | mode = AR5K_MODE_11G; | 1083 | mode = AR5K_MODE_11G; |
1086 | freq = AR5K_INI_RFGAIN_2GHZ; | ||
1087 | ee_mode = AR5K_EEPROM_MODE_11G; | 1084 | ee_mode = AR5K_EEPROM_MODE_11G; |
1088 | break; | 1085 | break; |
1089 | case CHANNEL_B: | 1086 | case CHANNEL_B: |
@@ -1095,7 +1092,6 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1095 | } | 1092 | } |
1096 | 1093 | ||
1097 | mode = AR5K_MODE_11B; | 1094 | mode = AR5K_MODE_11B; |
1098 | freq = AR5K_INI_RFGAIN_2GHZ; | ||
1099 | ee_mode = AR5K_EEPROM_MODE_11B; | 1095 | ee_mode = AR5K_EEPROM_MODE_11B; |
1100 | break; | 1096 | break; |
1101 | case CHANNEL_XR: | 1097 | case CHANNEL_XR: |
@@ -1105,7 +1101,6 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1105 | return -EINVAL; | 1101 | return -EINVAL; |
1106 | } | 1102 | } |
1107 | mode = AR5K_MODE_XR; | 1103 | mode = AR5K_MODE_XR; |
1108 | freq = AR5K_INI_RFGAIN_5GHZ; | ||
1109 | ee_mode = AR5K_EEPROM_MODE_11A; | 1104 | ee_mode = AR5K_EEPROM_MODE_11A; |
1110 | break; | 1105 | break; |
1111 | default: | 1106 | default: |
@@ -1120,7 +1115,7 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1120 | */ | 1115 | */ |
1121 | if (fast) { | 1116 | if (fast) { |
1122 | ret = ath5k_hw_phy_init(ah, channel, mode, | 1117 | ret = ath5k_hw_phy_init(ah, channel, mode, |
1123 | ee_mode, freq, true); | 1118 | ee_mode, true); |
1124 | if (ret) { | 1119 | if (ret) { |
1125 | ATH5K_DBG(ah->ah_sc, ATH5K_DEBUG_RESET, | 1120 | ATH5K_DBG(ah->ah_sc, ATH5K_DEBUG_RESET, |
1126 | "fast chan change failed, falling back to normal reset\n"); | 1121 | "fast chan change failed, falling back to normal reset\n"); |
@@ -1256,7 +1251,7 @@ int ath5k_hw_reset(struct ath5k_hw *ah, enum nl80211_iftype op_mode, | |||
1256 | /* | 1251 | /* |
1257 | * Initialize PHY | 1252 | * Initialize PHY |
1258 | */ | 1253 | */ |
1259 | ret = ath5k_hw_phy_init(ah, channel, mode, ee_mode, freq, false); | 1254 | ret = ath5k_hw_phy_init(ah, channel, mode, ee_mode, false); |
1260 | if (ret) { | 1255 | if (ret) { |
1261 | ATH5K_ERR(ah->ah_sc, | 1256 | ATH5K_ERR(ah->ah_sc, |
1262 | "failed to initialize PHY (%i) !\n", ret); | 1257 | "failed to initialize PHY (%i) !\n", ret); |