diff options
author | John W. Linville <linville@tuxdriver.com> | 2009-12-30 15:25:08 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-12-30 15:25:08 -0500 |
commit | 891dc5e73783eeabd2a704a9425e2a199b39c9f9 (patch) | |
tree | 9b4478941c486d47a71bfce455b896c5dda7e811 /drivers/net/wireless/ath/ath9k/main.c | |
parent | e1781ed33a8809c58ad6c3b6d432d656446efa43 (diff) | |
parent | 55afc80b2ab100618c17af77915f75307b6bd5d1 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
Conflicts:
drivers/net/wireless/libertas/scan.c
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/main.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/main.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index 446bd23756e5..79fbbda15493 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c | |||
@@ -2504,6 +2504,9 @@ static void ath9k_stop(struct ieee80211_hw *hw) | |||
2504 | return; /* another wiphy still in use */ | 2504 | return; /* another wiphy still in use */ |
2505 | } | 2505 | } |
2506 | 2506 | ||
2507 | /* Ensure HW is awake when we try to shut it down. */ | ||
2508 | ath9k_ps_wakeup(sc); | ||
2509 | |||
2507 | if (ah->btcoex_hw.enabled) { | 2510 | if (ah->btcoex_hw.enabled) { |
2508 | ath9k_hw_btcoex_disable(ah); | 2511 | ath9k_hw_btcoex_disable(ah); |
2509 | if (ah->btcoex_hw.scheme == ATH_BTCOEX_CFG_3WIRE) | 2512 | if (ah->btcoex_hw.scheme == ATH_BTCOEX_CFG_3WIRE) |
@@ -2524,6 +2527,9 @@ static void ath9k_stop(struct ieee80211_hw *hw) | |||
2524 | /* disable HAL and put h/w to sleep */ | 2527 | /* disable HAL and put h/w to sleep */ |
2525 | ath9k_hw_disable(ah); | 2528 | ath9k_hw_disable(ah); |
2526 | ath9k_hw_configpcipowersave(ah, 1, 1); | 2529 | ath9k_hw_configpcipowersave(ah, 1, 1); |
2530 | ath9k_ps_restore(sc); | ||
2531 | |||
2532 | /* Finally, put the chip in FULL SLEEP mode */ | ||
2527 | ath9k_setpower(sc, ATH9K_PM_FULL_SLEEP); | 2533 | ath9k_setpower(sc, ATH9K_PM_FULL_SLEEP); |
2528 | 2534 | ||
2529 | sc->sc_flags |= SC_OP_INVALID; | 2535 | sc->sc_flags |= SC_OP_INVALID; |
@@ -2637,8 +2643,10 @@ static void ath9k_remove_interface(struct ieee80211_hw *hw, | |||
2637 | if ((sc->sc_ah->opmode == NL80211_IFTYPE_AP) || | 2643 | if ((sc->sc_ah->opmode == NL80211_IFTYPE_AP) || |
2638 | (sc->sc_ah->opmode == NL80211_IFTYPE_ADHOC) || | 2644 | (sc->sc_ah->opmode == NL80211_IFTYPE_ADHOC) || |
2639 | (sc->sc_ah->opmode == NL80211_IFTYPE_MESH_POINT)) { | 2645 | (sc->sc_ah->opmode == NL80211_IFTYPE_MESH_POINT)) { |
2646 | ath9k_ps_wakeup(sc); | ||
2640 | ath9k_hw_stoptxdma(sc->sc_ah, sc->beacon.beaconq); | 2647 | ath9k_hw_stoptxdma(sc->sc_ah, sc->beacon.beaconq); |
2641 | ath_beacon_return(sc, avp); | 2648 | ath_beacon_return(sc, avp); |
2649 | ath9k_ps_restore(sc); | ||
2642 | } | 2650 | } |
2643 | 2651 | ||
2644 | sc->sc_flags &= ~SC_OP_BEACONS; | 2652 | sc->sc_flags &= ~SC_OP_BEACONS; |
@@ -3087,15 +3095,21 @@ static int ath9k_ampdu_action(struct ieee80211_hw *hw, | |||
3087 | case IEEE80211_AMPDU_RX_STOP: | 3095 | case IEEE80211_AMPDU_RX_STOP: |
3088 | break; | 3096 | break; |
3089 | case IEEE80211_AMPDU_TX_START: | 3097 | case IEEE80211_AMPDU_TX_START: |
3098 | ath9k_ps_wakeup(sc); | ||
3090 | ath_tx_aggr_start(sc, sta, tid, ssn); | 3099 | ath_tx_aggr_start(sc, sta, tid, ssn); |
3091 | ieee80211_start_tx_ba_cb_irqsafe(vif, sta->addr, tid); | 3100 | ieee80211_start_tx_ba_cb_irqsafe(vif, sta->addr, tid); |
3101 | ath9k_ps_restore(sc); | ||
3092 | break; | 3102 | break; |
3093 | case IEEE80211_AMPDU_TX_STOP: | 3103 | case IEEE80211_AMPDU_TX_STOP: |
3104 | ath9k_ps_wakeup(sc); | ||
3094 | ath_tx_aggr_stop(sc, sta, tid); | 3105 | ath_tx_aggr_stop(sc, sta, tid); |
3095 | ieee80211_stop_tx_ba_cb_irqsafe(vif, sta->addr, tid); | 3106 | ieee80211_stop_tx_ba_cb_irqsafe(vif, sta->addr, tid); |
3107 | ath9k_ps_restore(sc); | ||
3096 | break; | 3108 | break; |
3097 | case IEEE80211_AMPDU_TX_OPERATIONAL: | 3109 | case IEEE80211_AMPDU_TX_OPERATIONAL: |
3110 | ath9k_ps_wakeup(sc); | ||
3098 | ath_tx_aggr_resume(sc, sta, tid); | 3111 | ath_tx_aggr_resume(sc, sta, tid); |
3112 | ath9k_ps_restore(sc); | ||
3099 | break; | 3113 | break; |
3100 | default: | 3114 | default: |
3101 | ath_print(ath9k_hw_common(sc->sc_ah), ATH_DBG_FATAL, | 3115 | ath_print(ath9k_hw_common(sc->sc_ah), ATH_DBG_FATAL, |