diff options
author | Bob Copeland <me@bobcopeland.com> | 2009-08-07 06:33:11 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-14 09:13:37 -0400 |
commit | 08d9f57251841e4870cfd286e867ffcbef81d9a4 (patch) | |
tree | 98cff0725677bd4126b9e4fb0a095fe1be83741e /drivers/net/wireless/wl12xx/wl1251.h | |
parent | 6c766f413c81d5a11588552934fa093eab6ae06e (diff) |
wl1251: introduce wl1251_if_operations struct
Introduce an ops struct with read, write, and reset functions to
abstract away the details of the wl1251 bus interface. Doing this
will allow SDIO to coexist with SPI by supplying its own I/O
routines.
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.h')
-rw-r--r-- | drivers/net/wireless/wl12xx/wl1251.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/wireless/wl12xx/wl1251.h b/drivers/net/wireless/wl12xx/wl1251.h index 665aca02bea9..284bb508c87b 100644 --- a/drivers/net/wireless/wl12xx/wl1251.h +++ b/drivers/net/wireless/wl12xx/wl1251.h | |||
@@ -281,11 +281,18 @@ struct wl1251_debugfs { | |||
281 | struct dentry *excessive_retries; | 281 | struct dentry *excessive_retries; |
282 | }; | 282 | }; |
283 | 283 | ||
284 | struct wl1251_if_operations { | ||
285 | void (*read)(struct wl1251 *wl, int addr, void *buf, size_t len); | ||
286 | void (*write)(struct wl1251 *wl, int addr, void *buf, size_t len); | ||
287 | void (*reset)(struct wl1251 *wl); | ||
288 | }; | ||
289 | |||
284 | struct wl1251 { | 290 | struct wl1251 { |
285 | struct ieee80211_hw *hw; | 291 | struct ieee80211_hw *hw; |
286 | bool mac80211_registered; | 292 | bool mac80211_registered; |
287 | 293 | ||
288 | struct spi_device *spi; | 294 | struct spi_device *spi; |
295 | struct wl1251_if_operations *if_ops; | ||
289 | 296 | ||
290 | void (*set_power)(bool enable); | 297 | void (*set_power)(bool enable); |
291 | int irq; | 298 | int irq; |