aboutsummaryrefslogtreecommitdiffstats
path: root/package/mac80211/patches/520-ath9k_ps_survey_fix.patch
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2010-10-19 22:11:21 +0000
committerFelix Fietkau <nbd@openwrt.org>2010-10-19 22:11:21 +0000
commitd00018e3e301d9e7041e6d86ba9e8f513795a384 (patch)
tree2a85d658733c0b6c9e55ba60e2d585d7e0868d8b /package/mac80211/patches/520-ath9k_ps_survey_fix.patch
parentc1a522303f07612ceb4a827cad355ab8f0d2a397 (diff)
downloadmaster-187ad058-d00018e3e301d9e7041e6d86ba9e8f513795a384.tar.gz
master-187ad058-d00018e3e301d9e7041e6d86ba9e8f513795a384.tar.bz2
master-187ad058-d00018e3e301d9e7041e6d86ba9e8f513795a384.zip
mac80211: update to wireless-testing 2010-10-19
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@23540 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/mac80211/patches/520-ath9k_ps_survey_fix.patch')
-rw-r--r--package/mac80211/patches/520-ath9k_ps_survey_fix.patch54
1 files changed, 0 insertions, 54 deletions
diff --git a/package/mac80211/patches/520-ath9k_ps_survey_fix.patch b/package/mac80211/patches/520-ath9k_ps_survey_fix.patch
deleted file mode 100644
index f130f4132e..0000000000
--- a/package/mac80211/patches/520-ath9k_ps_survey_fix.patch
+++ /dev/null
@@ -1,54 +0,0 @@
---- a/drivers/net/wireless/ath/ath9k/main.c
-+++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -122,6 +122,7 @@ bool ath9k_setpower(struct ath_softc *sc
-
- void ath9k_ps_wakeup(struct ath_softc *sc)
- {
-+ struct ath_common *common = ath9k_hw_common(sc->sc_ah);
- unsigned long flags;
-
- spin_lock_irqsave(&sc->sc_pm_lock, flags);
-@@ -130,18 +131,33 @@ void ath9k_ps_wakeup(struct ath_softc *s
-
- ath9k_hw_setpower(sc->sc_ah, ATH9K_PM_AWAKE);
-
-+ /*
-+ * While the hardware is asleep, the cycle counters contain no
-+ * useful data. Better clear them now so that they don't mess up the
-+ * ANI or survey data results.
-+ */
-+ spin_lock(&common->cc_lock);
-+ ath_hw_cycle_counters_update(common);
-+ memset(&common->cc_survey, 0, sizeof(common->cc_survey));
-+ spin_unlock(&common->cc_lock);
-+
- unlock:
- spin_unlock_irqrestore(&sc->sc_pm_lock, flags);
- }
-
- void ath9k_ps_restore(struct ath_softc *sc)
- {
-+ struct ath_common *common = ath9k_hw_common(sc->sc_ah);
- unsigned long flags;
-
- spin_lock_irqsave(&sc->sc_pm_lock, flags);
- if (--sc->ps_usecount != 0)
- goto unlock;
-
-+ spin_lock(&common->cc_lock);
-+ ath_hw_cycle_counters_update(common);
-+ spin_unlock(&common->cc_lock);
-+
- if (sc->ps_idle)
- ath9k_hw_setpower(sc->sc_ah, ATH9K_PM_FULL_SLEEP);
- else if (sc->ps_enabled &&
-@@ -197,7 +213,8 @@ static void ath_update_survey_stats(stru
- struct ath_cycle_counters *cc = &common->cc_survey;
- unsigned int div = common->clockrate * 1000;
-
-- ath_hw_cycle_counters_update(common);
-+ if (ah->power_mode == ATH9K_PM_AWAKE)
-+ ath_hw_cycle_counters_update(common);
-
- if (cc->cycles > 0) {
- survey->filled |= SURVEY_INFO_CHANNEL_TIME |