diff options
author | Greg Ungerer <gerg@uclinux.org> | 2013-04-29 10:04:46 +1000 |
---|---|---|
committer | Greg Ungerer <gerg@uclinux.org> | 2013-05-29 16:56:45 +1000 |
commit | cf6c31fc5c3de225348742c95cc6185fca20a2f2 (patch) | |
tree | 1dc722427045b1a0d2cde448f4fce3bc54487a95 /arch/m68k | |
parent | e4aa937ec75df0eea0bee03bffa3303ad36c986b (diff) | |
download | op-kernel-dev-cf6c31fc5c3de225348742c95cc6185fca20a2f2.zip op-kernel-dev-cf6c31fc5c3de225348742c95cc6185fca20a2f2.tar.gz |
m68k: only use local gpio_request_one if not using GPIOLIB
Compiling for targets that use the local gpio code (not GPIOLIB) fail to
compile with:
CC arch/m68k/platform/coldfire/device.o
In file included from include/linux/gpio.h:45:0,
from arch/m68k/platform/coldfire/device.c:15:
/home/gerg/new-wave.git/linux-3.x/arch/m68k/include/asm/gpio.h:89:19: error: static declaration of ‘gpio_request_one’ follows non-static declaration
include/asm-generic/gpio.h:195:12: note: previous declaration of ‘gpio_request_one’ was here
Fix by conditionally using the local gpio_request_one() function based on
!CONFIG_GPIOLIB.
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
Diffstat (limited to 'arch/m68k')
-rw-r--r-- | arch/m68k/include/asm/gpio.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/m68k/include/asm/gpio.h b/arch/m68k/include/asm/gpio.h index 8cc8343..2f6eec1 100644 --- a/arch/m68k/include/asm/gpio.h +++ b/arch/m68k/include/asm/gpio.h @@ -86,6 +86,7 @@ static inline int gpio_cansleep(unsigned gpio) return gpio < MCFGPIO_PIN_MAX ? 0 : __gpio_cansleep(gpio); } +#ifndef CONFIG_GPIOLIB static inline int gpio_request_one(unsigned gpio, unsigned long flags, const char *label) { int err; @@ -105,5 +106,5 @@ static inline int gpio_request_one(unsigned gpio, unsigned long flags, const cha return err; } - +#endif /* !CONFIG_GPIOLIB */ #endif |