aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMohammed Shafi Shajakhan <mshajakhan@atheros.com>2010-12-07 10:44:15 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-12-07 17:08:08 -0500
commit0ce3bcfc84900a64347b0fe1140229bd81314008 (patch)
tree5eb6146682a54fe5ad4ac091e66101fa90246e1f
parentaaef24b4c9f5db726e618977b74ffef924360de5 (diff)
ath9k: Parse DTIM period from mac80211
With the current save power save implementation we assume a dtim period of 1.This value is assigned based on a sanity check in the driver eventhough we had not parsed it from mac80211.This patch obtains the actual DTIM period from AP by parsing it from mac80211.Yet for handling multicast traffic we may still have it as fixed rather than parsing it from mac80211 .This does not breaks power save or anything as the sleep duration is currently fixed in the driver.This patch may serve to improve power save in the future by using dtim period for sleep duration and using correct dtim period adhoc mode. Signed-off-by: Mohammed Shafi Shajakhan <mshajakhan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_init.c3
-rw-r--r--drivers/net/wireless/ath/ath9k/init.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_init.c b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
index 680cd369f144..93f3f615218b 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_init.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
@@ -714,7 +714,8 @@ static void ath9k_set_hw_capab(struct ath9k_htc_priv *priv,
714 IEEE80211_HW_HAS_RATE_CONTROL | 714 IEEE80211_HW_HAS_RATE_CONTROL |
715 IEEE80211_HW_RX_INCLUDES_FCS | 715 IEEE80211_HW_RX_INCLUDES_FCS |
716 IEEE80211_HW_SUPPORTS_PS | 716 IEEE80211_HW_SUPPORTS_PS |
717 IEEE80211_HW_PS_NULLFUNC_STACK; 717 IEEE80211_HW_PS_NULLFUNC_STACK |
718 IEEE80211_HW_NEED_DTIM_PERIOD;
718 719
719 hw->wiphy->interface_modes = 720 hw->wiphy->interface_modes =
720 BIT(NL80211_IFTYPE_STATION) | 721 BIT(NL80211_IFTYPE_STATION) |
diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c
index bd451c243689..b2983ce19dfb 100644
--- a/drivers/net/wireless/ath/ath9k/init.c
+++ b/drivers/net/wireless/ath/ath9k/init.c
@@ -642,7 +642,8 @@ void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw)
642 IEEE80211_HW_SUPPORTS_PS | 642 IEEE80211_HW_SUPPORTS_PS |
643 IEEE80211_HW_PS_NULLFUNC_STACK | 643 IEEE80211_HW_PS_NULLFUNC_STACK |
644 IEEE80211_HW_SPECTRUM_MGMT | 644 IEEE80211_HW_SPECTRUM_MGMT |
645 IEEE80211_HW_REPORTS_TX_ACK_STATUS; 645 IEEE80211_HW_REPORTS_TX_ACK_STATUS |
646 IEEE80211_HW_NEED_DTIM_PERIOD;
646 647
647 if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_HT) 648 if (sc->sc_ah->caps.hw_caps & ATH9K_HW_CAP_HT)
648 hw->flags |= IEEE80211_HW_AMPDU_AGGREGATION; 649 hw->flags |= IEEE80211_HW_AMPDU_AGGREGATION;