summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2012-03-10 12:59:28 +0000
committerFelix Fietkau <nbd@openwrt.org>2012-03-10 12:59:28 +0000
commit1812fe63b223bfcc286778ceb51d0af615df4858 (patch)
treee72bcbc8dccd5acdd90fd1e7f914d197153a2f25
parent414f23e49dbc6307252f57219262faaa50ec9ee8 (diff)
downloadmtk-20170518-1812fe63b223bfcc286778ceb51d0af615df4858.zip
mtk-20170518-1812fe63b223bfcc286778ceb51d0af615df4858.tar.gz
mtk-20170518-1812fe63b223bfcc286778ceb51d0af615df4858.tar.bz2
ath9k: merge a fix for hardware full sleep
SVN-Revision: 30864
-rw-r--r--package/mac80211/patches/300-pending_work.patch23
-rw-r--r--package/mac80211/patches/410-ath9k_allow_adhoc_and_ap.patch4
-rw-r--r--package/mac80211/patches/513-ath9k_channelbw_debugfs.patch6
-rw-r--r--package/mac80211/patches/531-ath9k_cur_txpower.patch4
4 files changed, 28 insertions, 9 deletions
diff --git a/package/mac80211/patches/300-pending_work.patch b/package/mac80211/patches/300-pending_work.patch
index b96e154..70c823a 100644
--- a/package/mac80211/patches/300-pending_work.patch
+++ b/package/mac80211/patches/300-pending_work.patch
@@ -1390,7 +1390,26 @@
EXPORT_SYMBOL(ath9k_hw_beaconq_setup);
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -2300,6 +2300,7 @@ static int ath9k_tx_last_beacon(struct i
+@@ -118,13 +118,15 @@ void ath9k_ps_restore(struct ath_softc *
+ if (--sc->ps_usecount != 0)
+ goto unlock;
+
+- if (sc->ps_idle && (sc->ps_flags & PS_WAIT_FOR_TX_ACK))
++ if (sc->ps_flags & PS_WAIT_FOR_TX_ACK)
++ goto unlock;
++
++ if (sc->ps_idle)
+ mode = ATH9K_PM_FULL_SLEEP;
+ else if (sc->ps_enabled &&
+ !(sc->ps_flags & (PS_WAIT_FOR_BEACON |
+ PS_WAIT_FOR_CAB |
+- PS_WAIT_FOR_PSPOLL_DATA |
+- PS_WAIT_FOR_TX_ACK)))
++ PS_WAIT_FOR_PSPOLL_DATA)))
+ mode = ATH9K_PM_NETWORK_SLEEP;
+ else
+ goto unlock;
+@@ -2300,6 +2302,7 @@ static int ath9k_tx_last_beacon(struct i
struct ath_vif *avp;
struct ath_buf *bf;
struct ath_tx_status ts;
@@ -1398,7 +1417,7 @@
int status;
vif = sc->beacon.bslot[0];
-@@ -2310,7 +2311,7 @@ static int ath9k_tx_last_beacon(struct i
+@@ -2310,7 +2313,7 @@ static int ath9k_tx_last_beacon(struct i
if (!avp->is_bslot_active)
return 0;
diff --git a/package/mac80211/patches/410-ath9k_allow_adhoc_and_ap.patch b/package/mac80211/patches/410-ath9k_allow_adhoc_and_ap.patch
index 6a39995..0962406 100644
--- a/package/mac80211/patches/410-ath9k_allow_adhoc_and_ap.patch
+++ b/package/mac80211/patches/410-ath9k_allow_adhoc_and_ap.patch
@@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -1430,15 +1430,6 @@ static int ath9k_add_interface(struct ie
+@@ -1432,15 +1432,6 @@ static int ath9k_add_interface(struct ie
}
}
@@ -16,7 +16,7 @@
ath_dbg(common, CONFIG, "Attach a VIF of type: %d\n", vif->type);
sc->nvifs++;
-@@ -1463,15 +1454,6 @@ static int ath9k_change_interface(struct
+@@ -1465,15 +1456,6 @@ static int ath9k_change_interface(struct
mutex_lock(&sc->mutex);
ath9k_ps_wakeup(sc);
diff --git a/package/mac80211/patches/513-ath9k_channelbw_debugfs.patch b/package/mac80211/patches/513-ath9k_channelbw_debugfs.patch
index 34e5ea1..2645d5b 100644
--- a/package/mac80211/patches/513-ath9k_channelbw_debugfs.patch
+++ b/package/mac80211/patches/513-ath9k_channelbw_debugfs.patch
@@ -80,7 +80,7 @@
}
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -1535,7 +1535,7 @@ static void ath9k_disable_ps(struct ath_
+@@ -1537,7 +1537,7 @@ static void ath9k_disable_ps(struct ath_
}
@@ -89,7 +89,7 @@
{
struct ath_softc *sc = hw->priv;
struct ath_hw *ah = sc->sc_ah;
-@@ -1579,9 +1579,11 @@ static int ath9k_config(struct ieee80211
+@@ -1581,9 +1581,11 @@ static int ath9k_config(struct ieee80211
if (changed & IEEE80211_CONF_CHANGE_CHANNEL) {
struct ieee80211_channel *curchan = hw->conf.channel;
@@ -101,7 +101,7 @@
if (ah->curchan)
old_pos = ah->curchan - &ah->channels[0];
-@@ -1629,7 +1631,23 @@ static int ath9k_config(struct ieee80211
+@@ -1631,7 +1633,23 @@ static int ath9k_config(struct ieee80211
memset(&sc->survey[pos], 0, sizeof(struct survey_info));
}
diff --git a/package/mac80211/patches/531-ath9k_cur_txpower.patch b/package/mac80211/patches/531-ath9k_cur_txpower.patch
index 46f2004..af246a7 100644
--- a/package/mac80211/patches/531-ath9k_cur_txpower.patch
+++ b/package/mac80211/patches/531-ath9k_cur_txpower.patch
@@ -1,6 +1,6 @@
--- a/drivers/net/wireless/ath/ath9k/main.c
+++ b/drivers/net/wireless/ath/ath9k/main.c
-@@ -1653,6 +1653,8 @@ int ath9k_config(struct ieee80211_hw *hw
+@@ -1655,6 +1655,8 @@ int ath9k_config(struct ieee80211_hw *hw
return -EINVAL;
}
@@ -9,7 +9,7 @@
/*
* The most recent snapshot of channel->noisefloor for the old
* channel is only available after the hardware reset. Copy it to
-@@ -1667,6 +1669,7 @@ int ath9k_config(struct ieee80211_hw *hw
+@@ -1669,6 +1671,7 @@ int ath9k_config(struct ieee80211_hw *hw
sc->config.txpowlimit = 2 * conf->power_level;
ath9k_cmn_update_txpow(ah, sc->curtxpow,
sc->config.txpowlimit, &sc->curtxpow);