1 #ifndef _ARCH_ARM_GPIO_H
2 #define _ARCH_ARM_GPIO_H
4 #if CONFIG_ARCH_NR_GPIO > 0
5 #define ARCH_NR_GPIOS CONFIG_ARCH_NR_GPIO
8 /* not all ARM platforms necessarily support this API ... */
9 #ifdef CONFIG_NEED_MACH_GPIO_H
10 #include <mach/gpio.h>
13 #ifndef __ARM_GPIOLIB_COMPLEX
14 /* Note: this may rely upon the value of ARCH_NR_GPIOS set in mach/gpio.h */
15 #include <asm-generic/gpio.h>
17 /* The trivial gpiolib dispatchers */
18 #define gpio_get_value __gpio_get_value
19 #define gpio_set_value __gpio_set_value
20 #define gpio_cansleep __gpio_cansleep
24 * Provide a default gpio_to_irq() which should satisfy every case.
25 * However, some platforms want to do this differently, so allow them
29 #define gpio_to_irq __gpio_to_irq
32 #endif /* _ARCH_ARM_GPIO_H */