diff options
author | Bob Copeland <me@bobcopeland.com> | 2009-08-07 12:33:18 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-14 15:13:37 +0200 |
commit | 0d77e141331b25adf190ce30d69fe5744a69c5bd (patch) | |
tree | 1e62aa4ab8d08c0653443e2bf086ea55f04a8441 /drivers/net/wireless/wl12xx/wl1251_io.h | |
parent | wl1251: introduce wl1251_if_operations struct (diff) | |
download | linux-0d77e141331b25adf190ce30d69fe5744a69c5bd.tar.xz linux-0d77e141331b25adf190ce30d69fe5744a69c5bd.zip |
wl1251: make wl1251_set_partition bus agnostic
The same partition setting code can be used for both SPI and SDIO
modes, if we remove the spi-specific commands and use the more
generic buffer write routines. Do that and move it to io.c
since it deals with register/memory address offsets.
Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/wl12xx/wl1251_io.h')
-rw-r--r-- | drivers/net/wireless/wl12xx/wl1251_io.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251_io.h b/drivers/net/wireless/wl12xx/wl1251_io.h index 1fa2ab18a9e1..b89d2ac62efb 100644 --- a/drivers/net/wireless/wl12xx/wl1251_io.h +++ b/drivers/net/wireless/wl12xx/wl1251_io.h @@ -23,6 +23,17 @@ #include "wl1251.h" +#define HW_ACCESS_MEMORY_MAX_RANGE 0x1FFC0 + +#define HW_ACCESS_PART0_SIZE_ADDR 0x1FFC0 +#define HW_ACCESS_PART0_START_ADDR 0x1FFC4 +#define HW_ACCESS_PART1_SIZE_ADDR 0x1FFC8 +#define HW_ACCESS_PART1_START_ADDR 0x1FFCC + +#define HW_ACCESS_REGISTER_SIZE 4 + +#define HW_ACCESS_PRAM_MAX_RANGE 0x3c000 + static inline u32 wl1251_read32(struct wl1251 *wl, int addr) { u32 response; @@ -46,4 +57,8 @@ void wl1251_mem_write32(struct wl1251 *wl, int addr, u32 val); u32 wl1251_reg_read32(struct wl1251 *wl, int addr); void wl1251_reg_write32(struct wl1251 *wl, int addr, u32 val); +void wl1251_set_partition(struct wl1251 *wl, + u32 part_start, u32 part_size, + u32 reg_start, u32 reg_size); + #endif |