omap: zoom2: fix build break when CONFIG_WL12XX_PLATFORM_DATA=n
PATCH 1/1 omap: zoom2: fix build break when CONFIG_WL12XX_PLATFORM_DATA=n
Fix this build break when CONFIG_WL12XX_PLATFORM_DATA is not set.
LD .tmp_vmlinux1arch/arm/mach-omap2/built-in.o: In function `zoom_peripherals_init':/home/userdata/a0393673/kernels/mainline/linux-2.6/arch/arm/mach-omap2/board-zoom-peripherals.c:333: undefined reference to `wl12xx_set_platform_data'
make: *** [.tmp_vmlinux1] Error 1
---
There are still many warnings about the function wl12xx_set_platform_data being unused. Haven't fixed those. Ohad, care to take a look?
include/linux/wl12xx.h | 7 +++++++ 1 file changed, 7 insertions(+)
include/linux/wl12xx.h +7 -0
@@ -32,7 +32,14 @@ struct wl12xx_platform_data { int board_ref_clock; }; +#ifdef CONFIG_WL12XX_PLATFORM_DATA int wl12xx_set_platform_data (const struct wl12xx_platform_data *data); +#else +static int wl12xx_set_platform_data (const struct wl12xx_platform_data *data) +{ +return 0 ; +} +#endif const struct wl12xx_platform_data *wl12xx_get_platform_data (void );#endif
Quoted 1 line · Anand Gadiyar
Fix this build break when
CONFIG_WL12XX_PLATFORM_DATAis not set.
A similar fix was already submitted and is pending to be merged
(http://permalink.gmane.org/gmane.linux.kernel.wireless.general/56595)
Quoted 2 lines
There are still many warnings about the function
wl12xx_set_platform_databeing unused. Haven't fixed those. Ohad, care to take a look?
Sure. Which warnings do you refer to (I haven't seen any) ?
Thanks,
Ohad.
Quoted 14 lines
include/linux/wl12xx.h | 7 +++++++
1 file changed, 7 insertions(+)Index:
linux-2.6/include/linux/wl12xx.h
===================================================================include/linux/wl12xx.h +1
-0@@ -32,7 +32,14 @@ struct wl12xx_platform_data { int board_ref_clock; }; +#ifdef CONFIG_WL12XX_PLATFORM_DATA
include/linux/wl12xx.h struct wl12xx_platform_data { · line 45
Quoted 10 lines
include/linux/wl12xx.h +6
-0int wl12xx_set_platform_data(const struct wl12xx_platform_data *data); +#else +static int wl12xx_set_platform_data (const struct wl12xx_platform_data *data) +{ + return 0; +} +#endif const struct wl12xx_platform_data *wl12xx_get_platform_data(void); #endif
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 7 lines · Ohad Ben-Cohen
Quoted 1 line · Anand Gadiyar
Fix this build break when
CONFIG_WL12XX_PLATFORM_DATAis not set.A similar fix was already submitted and is pending to be merged
(http://permalink.gmane.org/gmane.linux.kernel.wireless.general/56595)Quoted 1 line
There are still many warnings about the function
wl12xx_set_platform_data
Quoted 4 lines
Quoted 1 line
being unused. Haven't fixed those. Ohad, care to take a look?
Sure. Which warnings do you refer to (I haven't seen any) ?
I picked up your patch and the warnings are gone. The key difference was I missed marking the alternative function as an inline.
Without that, I was seeing warnings like these:include/linux/wl12xx.h:42: warning: 'wl12xx_set_platform_data' defined but not used
- Anand
Quoted 2 lines · Anand Gadiyar
I picked up your patch and the warnings are gone. The key difference was I missed marking the alternative function as an inline.
Ok, thanks for the update.
Quoted 7 lines
Without that, I was seeing warnings like these:
include/linux/wl12xx.h:42: warning: 'wl12xx_set_platform_data' defined but not used- Anand