aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath6kl/cfg80211.c
diff options
context:
space:
mode:
authorRaja Mani <rmani@qca.qualcomm.com>2011-11-07 15:52:46 -0500
committerKalle Valo <kvalo@qca.qualcomm.com>2011-11-11 06:00:00 -0500
commita918fb3cc6a58f918f36348c43c3170bb88bc599 (patch)
treeeeacc514e03652d9147917b3cdd2103c4cd60a53 /drivers/net/wireless/ath/ath6kl/cfg80211.c
parentd7c44e0ba5003c22a9ff3545fc2f51eaca8a95b1 (diff)
ath6kl: Perform WOW resume in RX path in case of SDIO IRQ wake up
The target triggers sdio data line to wake up the host when WOW pattern matches. This causes sdio irq handler is being executed in the host side which internally hits ath6kl's RX path. WOW resume should happen before start processing any data from the target. So it's required to perform WOW resume in RX path. This area needs bit rework to avoid WOW resume in RX path, As of now it's fine to have this model, rework will be done later. Signed-off-by: Raja Mani <rmani@qca.qualcomm.com> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath6kl/cfg80211.c')
-rw-r--r--drivers/net/wireless/ath/ath6kl/cfg80211.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c
index 0e3ecf814635..c981e137e1d1 100644
--- a/drivers/net/wireless/ath/ath6kl/cfg80211.c
+++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c
@@ -1886,6 +1886,34 @@ static int __ath6kl_cfg80211_resume(struct wiphy *wiphy)
1886 1886
1887 return ath6kl_hif_resume(ar); 1887 return ath6kl_hif_resume(ar);
1888} 1888}
1889
1890/*
1891 * FIXME: WOW suspend mode is selected if the host sdio controller supports
1892 * both sdio irq wake up and keep power. The target pulls sdio data line to
1893 * wake up the host when WOW pattern matches. This causes sdio irq handler
1894 * is being called in the host side which internally hits ath6kl's RX path.
1895 *
1896 * Since sdio interrupt is not disabled, RX path executes even before
1897 * the host executes the actual resume operation from PM module.
1898 *
1899 * In the current scenario, WOW resume should happen before start processing
1900 * any data from the target. So It's required to perform WOW resume in RX path.
1901 * Ideally we should perform WOW resume only in the actual platform
1902 * resume path. This area needs bit rework to avoid WOW resume in RX path.
1903 *
1904 * ath6kl_check_wow_status() is called from ath6kl_rx().
1905 */
1906void ath6kl_check_wow_status(struct ath6kl *ar)
1907{
1908 if (ar->state == ATH6KL_STATE_WOW)
1909 ath6kl_cfg80211_resume(ar);
1910}
1911
1912#else
1913
1914void ath6kl_check_wow_status(struct ath6kl *ar)
1915{
1916}
1889#endif 1917#endif
1890 1918
1891static int ath6kl_set_channel(struct wiphy *wiphy, struct net_device *dev, 1919static int ath6kl_set_channel(struct wiphy *wiphy, struct net_device *dev,