]>
Commit | Line | Data |
---|---|---|
4c20386c DB |
1 | #ifndef _ARCH_ARM_GPIO_H |
2 | #define _ARCH_ARM_GPIO_H | |
3 | ||
44986ab0 PDSN |
4 | #if CONFIG_ARCH_NR_GPIO > 0 |
5 | #define ARCH_NR_GPIO CONFIG_ARCH_NR_GPIO | |
6 | #endif | |
7 | ||
4c20386c | 8 | /* not all ARM platforms necessarily support this API ... */ |
a09e64fb | 9 | #include <mach/gpio.h> |
4c20386c | 10 | |
8f3c4537 | 11 | #ifndef __ARM_GPIOLIB_COMPLEX |
22fe6783 RK |
12 | /* Note: this may rely upon the value of ARCH_NR_GPIOS set in mach/gpio.h */ |
13 | #include <asm-generic/gpio.h> | |
14 | ||
15 | /* The trivial gpiolib dispatchers */ | |
16 | #define gpio_get_value __gpio_get_value | |
17 | #define gpio_set_value __gpio_set_value | |
18 | #define gpio_cansleep __gpio_cansleep | |
19 | #endif | |
20 | ||
01e7dc89 RK |
21 | /* |
22 | * Provide a default gpio_to_irq() which should satisfy every case. | |
23 | * However, some platforms want to do this differently, so allow them | |
24 | * to override it. | |
25 | */ | |
26 | #ifndef gpio_to_irq | |
27 | #define gpio_to_irq __gpio_to_irq | |
28 | #endif | |
29 | ||
4c20386c | 30 | #endif /* _ARCH_ARM_GPIO_H */ |