diff options
author | Juuso Oikarinen <juuso.oikarinen@nokia.com> | 2009-10-08 14:56:23 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-10-27 16:47:49 -0400 |
commit | 545f1da8ef0f20923feb500bcfaf0e2fb6068fb4 (patch) | |
tree | b245ba9ed9abffa9f53de1cd33f7c3108eb8fa6a /drivers/net/wireless/wl12xx/wl1271.h | |
parent | c3fea1994ac34dafa3ebb40d4f95354b2782af31 (diff) |
wl1271: Implementation for SPI busy word checking
This patch adds implementation for checking for SPI busy words - i.e.
honoring a delay request from the WLAN chipset upon reading
registers/memory.
To optimized the average SPI ready by 32 bits, also configure the number
of busywords to one to disable the "fixed-busy-word" functionality.
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Reviewed-by: Vidhya Govindan <vidhya.govindan@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/wl1271.h')
-rw-r--r-- | drivers/net/wireless/wl12xx/wl1271.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271.h b/drivers/net/wireless/wl12xx/wl1271.h index c455dcbae524..957da8c0d9cb 100644 --- a/drivers/net/wireless/wl12xx/wl1271.h +++ b/drivers/net/wireless/wl12xx/wl1271.h | |||
@@ -107,7 +107,13 @@ enum { | |||
107 | #define WL1271_FW_NAME "wl1271-fw.bin" | 107 | #define WL1271_FW_NAME "wl1271-fw.bin" |
108 | #define WL1271_NVS_NAME "wl1271-nvs.bin" | 108 | #define WL1271_NVS_NAME "wl1271-nvs.bin" |
109 | 109 | ||
110 | #define WL1271_BUSY_WORD_LEN 8 | 110 | /* |
111 | * FIXME: for the wl1271, a busy word count of 1 here will result in a more | ||
112 | * optimal SPI interface. There is some SPI bug however, causing RXS time outs | ||
113 | * with this mode occasionally on boot, so lets have two for now. | ||
114 | */ | ||
115 | #define WL1271_BUSY_WORD_CNT 2 | ||
116 | #define WL1271_BUSY_WORD_LEN (WL1271_BUSY_WORD_CNT * sizeof(u32)) | ||
111 | 117 | ||
112 | #define WL1271_ELP_HW_STATE_ASLEEP 0 | 118 | #define WL1271_ELP_HW_STATE_ASLEEP 0 |
113 | #define WL1271_ELP_HW_STATE_IRQ 1 | 119 | #define WL1271_ELP_HW_STATE_IRQ 1 |
@@ -389,7 +395,7 @@ struct wl1271 { | |||
389 | 395 | ||
390 | u32 buffer_32; | 396 | u32 buffer_32; |
391 | u32 buffer_cmd; | 397 | u32 buffer_cmd; |
392 | u8 buffer_busyword[WL1271_BUSY_WORD_LEN]; | 398 | u32 buffer_busyword[WL1271_BUSY_WORD_CNT]; |
393 | struct wl1271_rx_descriptor *rx_descriptor; | 399 | struct wl1271_rx_descriptor *rx_descriptor; |
394 | 400 | ||
395 | struct wl1271_fw_status *fw_status; | 401 | struct wl1271_fw_status *fw_status; |