diff options
| author | Luciano Coelho <coelho@ti.com> | 2013-01-25 05:05:34 -0500 |
|---|---|---|
| committer | Luciano Coelho <coelho@ti.com> | 2013-02-08 03:05:02 -0500 |
| commit | 6cc9efed707c575a9e5880ea68f8b9d36b235f1f (patch) | |
| tree | 205ce4c92ece7ea5c3020b9ce12ca801e08642af /include/linux | |
| parent | 06ab4058ea418d8503458bea386961b9dd554356 (diff) | |
wlcore: move wl12xx_platform_data up and make it truly optional
The platform data is used not only by wlcore-based drivers, but also
by wl1251. Move it up in the directory hierarchy to reflect this.
Additionally, make it truly optional. At the moment, disabling
platform data while wl1251_sdio or wlcore_sdio are enabled doesn't
work, but it will be necessary when device tree support is
implemented.
Signed-off-by: Luciano Coelho <coelho@ti.com>
Reviewed-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/wl12xx.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/include/linux/wl12xx.h b/include/linux/wl12xx.h index 360c9bce665c..a54fe82e704b 100644 --- a/include/linux/wl12xx.h +++ b/include/linux/wl12xx.h | |||
| @@ -24,6 +24,8 @@ | |||
| 24 | #ifndef _LINUX_WL12XX_H | 24 | #ifndef _LINUX_WL12XX_H |
| 25 | #define _LINUX_WL12XX_H | 25 | #define _LINUX_WL12XX_H |
| 26 | 26 | ||
| 27 | #include <linux/err.h> | ||
| 28 | |||
| 27 | /* Reference clock values */ | 29 | /* Reference clock values */ |
| 28 | enum { | 30 | enum { |
| 29 | WL12XX_REFCLOCK_19 = 0, /* 19.2 MHz */ | 31 | WL12XX_REFCLOCK_19 = 0, /* 19.2 MHz */ |
| @@ -60,10 +62,12 @@ struct wl12xx_platform_data { | |||
| 60 | /* Platform does not support level trigger interrupts */ | 62 | /* Platform does not support level trigger interrupts */ |
| 61 | #define WL12XX_PLATFORM_QUIRK_EDGE_IRQ BIT(0) | 63 | #define WL12XX_PLATFORM_QUIRK_EDGE_IRQ BIT(0) |
| 62 | 64 | ||
| 63 | #ifdef CONFIG_WL12XX_PLATFORM_DATA | 65 | #ifdef CONFIG_WILINK_PLATFORM_DATA |
| 64 | 66 | ||
| 65 | int wl12xx_set_platform_data(const struct wl12xx_platform_data *data); | 67 | int wl12xx_set_platform_data(const struct wl12xx_platform_data *data); |
| 66 | 68 | ||
| 69 | struct wl12xx_platform_data *wl12xx_get_platform_data(void); | ||
| 70 | |||
| 67 | #else | 71 | #else |
| 68 | 72 | ||
| 69 | static inline | 73 | static inline |
| @@ -72,8 +76,12 @@ int wl12xx_set_platform_data(const struct wl12xx_platform_data *data) | |||
| 72 | return -ENOSYS; | 76 | return -ENOSYS; |
| 73 | } | 77 | } |
| 74 | 78 | ||
| 75 | #endif | 79 | static inline |
| 80 | struct wl12xx_platform_data *wl12xx_get_platform_data(void) | ||
| 81 | { | ||
| 82 | return ERR_PTR(-ENODATA); | ||
| 83 | } | ||
| 76 | 84 | ||
| 77 | struct wl12xx_platform_data *wl12xx_get_platform_data(void); | 85 | #endif |
| 78 | 86 | ||
| 79 | #endif | 87 | #endif |
