diff options
author | Teemu Paasikivi <ext-teemu.3.paasikivi@nokia.com> | 2010-02-22 07:38:23 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-03-09 21:02:57 +0100 |
commit | 8197b7118add28f9aaa99c1fb73c0e201c8cde52 (patch) | |
tree | ce6c7c4cb5cdb8113b19d17b98d04929eef5030e /drivers/net/wireless/wl12xx/wl1271.h | |
parent | wl1271: Added functions to enable/disable interrupt handling (diff) | |
download | linux-8197b7118add28f9aaa99c1fb73c0e201c8cde52.tar.xz linux-8197b7118add28f9aaa99c1fb73c0e201c8cde52.zip |
wl1271: Implemented abstraction of IO functions.
Changed the driver to use if_ops structure to abstract access to the IO
layer (SPI or SDIO).
Signed-off-by: Teemu Paasikivi <ext-teemu.3.paasikivi@nokia.com>
Reviewed-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Signed-off-by: Juuso Oikarinen <juuso.oikarinen@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 | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1271.h b/drivers/net/wireless/wl12xx/wl1271.h index 97ea5096bc8c..10135c94e20e 100644 --- a/drivers/net/wireless/wl12xx/wl1271.h +++ b/drivers/net/wireless/wl12xx/wl1271.h @@ -334,11 +334,25 @@ struct wl1271_scan { u8 probe_requests; }; +struct wl1271_if_operations { + void (*read)(struct wl1271 *wl, int addr, void *buf, size_t len, + bool fixed); + void (*write)(struct wl1271 *wl, int addr, void *buf, size_t len, + bool fixed); + void (*reset)(struct wl1271 *wl); + void (*init)(struct wl1271 *wl); + struct device* (*dev)(struct wl1271 *wl); + void (*enable_irq)(struct wl1271 *wl); + void (*disable_irq)(struct wl1271 *wl); +}; + struct wl1271 { struct ieee80211_hw *hw; bool mac80211_registered; - struct spi_device *spi; + void *if_priv; + + struct wl1271_if_operations *if_ops; void (*set_power)(bool enable); int irq; |