diff options
Diffstat (limited to 'drivers/net/wireless/rtlwifi/rtl8192se/hw.c')
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192se/hw.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/drivers/net/wireless/rtlwifi/rtl8192se/hw.c b/drivers/net/wireless/rtlwifi/rtl8192se/hw.c index 2e9005d0454b..35dd12d0dcf3 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192se/hw.c +++ b/drivers/net/wireless/rtlwifi/rtl8192se/hw.c | |||
@@ -884,12 +884,10 @@ static void _rtl92se_hw_configure(struct ieee80211_hw *hw) | |||
884 | struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); | 884 | struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); |
885 | 885 | ||
886 | u8 reg_bw_opmode = 0; | 886 | u8 reg_bw_opmode = 0; |
887 | u32 reg_ratr = 0, reg_rrsr = 0; | 887 | u32 reg_rrsr = 0; |
888 | u8 regtmp = 0; | 888 | u8 regtmp = 0; |
889 | 889 | ||
890 | reg_bw_opmode = BW_OPMODE_20MHZ; | 890 | reg_bw_opmode = BW_OPMODE_20MHZ; |
891 | reg_ratr = RATE_ALL_CCK | RATE_ALL_OFDM_AG | RATE_ALL_OFDM_1SS | | ||
892 | RATE_ALL_OFDM_2SS; | ||
893 | reg_rrsr = RATE_ALL_CCK | RATE_ALL_OFDM_AG; | 891 | reg_rrsr = RATE_ALL_CCK | RATE_ALL_OFDM_AG; |
894 | 892 | ||
895 | regtmp = rtl_read_byte(rtlpriv, INIRTSMCS_SEL); | 893 | regtmp = rtl_read_byte(rtlpriv, INIRTSMCS_SEL); |
@@ -1122,14 +1120,12 @@ static int _rtl92se_set_media_status(struct ieee80211_hw *hw, | |||
1122 | { | 1120 | { |
1123 | struct rtl_priv *rtlpriv = rtl_priv(hw); | 1121 | struct rtl_priv *rtlpriv = rtl_priv(hw); |
1124 | u8 bt_msr = rtl_read_byte(rtlpriv, MSR); | 1122 | u8 bt_msr = rtl_read_byte(rtlpriv, MSR); |
1125 | enum led_ctl_mode ledaction = LED_CTL_NO_LINK; | ||
1126 | u32 temp; | 1123 | u32 temp; |
1127 | bt_msr &= ~MSR_LINK_MASK; | 1124 | bt_msr &= ~MSR_LINK_MASK; |
1128 | 1125 | ||
1129 | switch (type) { | 1126 | switch (type) { |
1130 | case NL80211_IFTYPE_UNSPECIFIED: | 1127 | case NL80211_IFTYPE_UNSPECIFIED: |
1131 | bt_msr |= (MSR_LINK_NONE << MSR_LINK_SHIFT); | 1128 | bt_msr |= (MSR_LINK_NONE << MSR_LINK_SHIFT); |
1132 | ledaction = LED_CTL_LINK; | ||
1133 | RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, | 1129 | RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, |
1134 | ("Set Network type to NO LINK!\n")); | 1130 | ("Set Network type to NO LINK!\n")); |
1135 | break; | 1131 | break; |
@@ -1140,7 +1136,6 @@ static int _rtl92se_set_media_status(struct ieee80211_hw *hw, | |||
1140 | break; | 1136 | break; |
1141 | case NL80211_IFTYPE_STATION: | 1137 | case NL80211_IFTYPE_STATION: |
1142 | bt_msr |= (MSR_LINK_MANAGED << MSR_LINK_SHIFT); | 1138 | bt_msr |= (MSR_LINK_MANAGED << MSR_LINK_SHIFT); |
1143 | ledaction = LED_CTL_LINK; | ||
1144 | RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, | 1139 | RT_TRACE(rtlpriv, COMP_INIT, DBG_TRACE, |
1145 | ("Set Network type to STA!\n")); | 1140 | ("Set Network type to STA!\n")); |
1146 | break; | 1141 | break; |
@@ -1231,6 +1226,7 @@ void rtl92se_disable_interrupt(struct ieee80211_hw *hw) | |||
1231 | rtl_write_dword(rtlpriv, INTA_MASK + 4, 0); | 1226 | rtl_write_dword(rtlpriv, INTA_MASK + 4, 0); |
1232 | 1227 | ||
1233 | rtlpci->irq_enabled = false; | 1228 | rtlpci->irq_enabled = false; |
1229 | synchronize_irq(rtlpci->pdev->irq); | ||
1234 | } | 1230 | } |
1235 | 1231 | ||
1236 | 1232 | ||
@@ -2271,7 +2267,7 @@ bool rtl92se_gpio_radio_on_off_checking(struct ieee80211_hw *hw, u8 *valid) | |||
2271 | struct rtl_priv *rtlpriv = rtl_priv(hw); | 2267 | struct rtl_priv *rtlpriv = rtl_priv(hw); |
2272 | struct rtl_ps_ctl *ppsc = rtl_psc(rtl_priv(hw)); | 2268 | struct rtl_ps_ctl *ppsc = rtl_psc(rtl_priv(hw)); |
2273 | struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw)); | 2269 | struct rtl_pci *rtlpci = rtl_pcidev(rtl_pcipriv(hw)); |
2274 | enum rf_pwrstate rfpwr_toset, cur_rfstate; | 2270 | enum rf_pwrstate rfpwr_toset /*, cur_rfstate */; |
2275 | unsigned long flag = 0; | 2271 | unsigned long flag = 0; |
2276 | bool actuallyset = false; | 2272 | bool actuallyset = false; |
2277 | bool turnonbypowerdomain = false; | 2273 | bool turnonbypowerdomain = false; |
@@ -2292,7 +2288,7 @@ bool rtl92se_gpio_radio_on_off_checking(struct ieee80211_hw *hw, u8 *valid) | |||
2292 | spin_unlock_irqrestore(&rtlpriv->locks.rf_ps_lock, flag); | 2288 | spin_unlock_irqrestore(&rtlpriv->locks.rf_ps_lock, flag); |
2293 | } | 2289 | } |
2294 | 2290 | ||
2295 | cur_rfstate = ppsc->rfpwr_state; | 2291 | /* cur_rfstate = ppsc->rfpwr_state;*/ |
2296 | 2292 | ||
2297 | /* because after _rtl92s_phy_set_rfhalt, all power | 2293 | /* because after _rtl92s_phy_set_rfhalt, all power |
2298 | * closed, so we must open some power for GPIO check, | 2294 | * closed, so we must open some power for GPIO check, |