summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx/debugfs.c
diff options
context:
space:
mode:
authorKalle Valo <kalle.valo@nokia.com>2009-06-12 14:16:26 +0300
committerJohn W. Linville <linville@tuxdriver.com>2009-07-10 14:57:47 -0400
commit01d9cfbdaadc64a46b57437c989bbad241074135 (patch)
tree8c3946f17ee1571515271ffa550c22a643b8bb33 /drivers/net/wireless/wl12xx/debugfs.c
parentcee4fd2712a3db21f432bdff14e59aed160453b2 (diff)
wl12xx: optimise elp wakeup and sleep calls
The wakeup call was done too deep in code path, it's better to wakeup chip from higher levels. This will also reduce wakeup calls significantly. Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Reviewed-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx/debugfs.c')
-rw-r--r--drivers/net/wireless/wl12xx/debugfs.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/debugfs.c b/drivers/net/wireless/wl12xx/debugfs.c
index cdb368ce4da..3cc5460c11f 100644
--- a/drivers/net/wireless/wl12xx/debugfs.c
+++ b/drivers/net/wireless/wl12xx/debugfs.c
@@ -27,6 +27,7 @@
#include "wl12xx.h"
#include "acx.h"
+#include "ps.h"
/* ms */
#define WL12XX_DEBUGFS_STATS_LIFETIME 1000
@@ -96,6 +97,8 @@ static void wl12xx_debugfs_update_stats(struct wl12xx *wl)
{
mutex_lock(&wl->mutex);
+ wl12xx_ps_elp_wakeup(wl);
+
if (wl->state == WL12XX_STATE_ON &&
time_after(jiffies, wl->stats.fw_stats_update +
msecs_to_jiffies(WL12XX_DEBUGFS_STATS_LIFETIME))) {
@@ -103,6 +106,8 @@ static void wl12xx_debugfs_update_stats(struct wl12xx *wl)
wl->stats.fw_stats_update = jiffies;
}
+ wl12xx_ps_elp_sleep(wl);
+
mutex_unlock(&wl->mutex);
}