summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/wl12xx/cmd.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/cmd.c
parentcee4fd2712a3db21f432bdff14e59aed160453b2 (diff)
downloadtalos-op-linux-01d9cfbdaadc64a46b57437c989bbad241074135.tar.gz
talos-op-linux-01d9cfbdaadc64a46b57437c989bbad241074135.zip
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/cmd.c')
-rw-r--r--drivers/net/wireless/wl12xx/cmd.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/net/wireless/wl12xx/cmd.c b/drivers/net/wireless/wl12xx/cmd.c
index 04e8401fcbed..fb4e9962d2c2 100644
--- a/drivers/net/wireless/wl12xx/cmd.c
+++ b/drivers/net/wireless/wl12xx/cmd.c
@@ -32,8 +32,6 @@ int wl12xx_cmd_send(struct wl12xx *wl, u16 id, void *buf, size_t len)
WARN_ON(len % 4 != 0);
- wl12xx_ps_elp_wakeup(wl);
-
wl12xx_spi_mem_write(wl, wl->cmd_box_addr, buf, len);
wl12xx_reg_write32(wl, ACX_REG_INTERRUPT_TRIG, INTR_TRIG_CMD);
@@ -57,8 +55,6 @@ int wl12xx_cmd_send(struct wl12xx *wl, u16 id, void *buf, size_t len)
wl->chip.intr_cmd_complete);
out:
- wl12xx_ps_elp_sleep(wl);
-
return ret;
}
@@ -91,13 +87,8 @@ int wl12xx_cmd_test(struct wl12xx *wl, void *buf, size_t buf_len, u8 answer)
* The answer would be a wl12xx_command, where the
* parameter array contains the actual answer.
*/
-
- wl12xx_ps_elp_wakeup(wl);
-
wl12xx_spi_mem_read(wl, wl->cmd_box_addr, buf, buf_len);
- wl12xx_ps_elp_sleep(wl);
-
cmd_answer = buf;
if (cmd_answer->header.status != CMD_STATUS_SUCCESS)
@@ -134,13 +125,9 @@ int wl12xx_cmd_interrogate(struct wl12xx *wl, u16 id, void *buf, size_t len)
goto out;
}
- wl12xx_ps_elp_wakeup(wl);
-
/* the interrogate command got in, we can read the answer */
wl12xx_spi_mem_read(wl, wl->cmd_box_addr, buf, len);
- wl12xx_ps_elp_sleep(wl);
-
acx = buf;
if (acx->cmd.status != CMD_STATUS_SUCCESS)
wl12xx_error("INTERROGATE command error: %d",
OpenPOWER on IntegriCloud