diff options
Diffstat (limited to 'include/asm-generic/gpio.h')
-rw-r--r-- | include/asm-generic/gpio.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h index 66d6106a2067..485eeb6c4ef3 100644 --- a/include/asm-generic/gpio.h +++ b/include/asm-generic/gpio.h | |||
@@ -28,6 +28,7 @@ static inline int gpio_is_valid(int number) | |||
28 | return ((unsigned)number) < ARCH_NR_GPIOS; | 28 | return ((unsigned)number) < ARCH_NR_GPIOS; |
29 | } | 29 | } |
30 | 30 | ||
31 | struct device; | ||
31 | struct seq_file; | 32 | struct seq_file; |
32 | struct module; | 33 | struct module; |
33 | 34 | ||
@@ -144,6 +145,7 @@ extern int __gpio_to_irq(unsigned gpio); | |||
144 | extern int gpio_export(unsigned gpio, bool direction_may_change); | 145 | extern int gpio_export(unsigned gpio, bool direction_may_change); |
145 | extern int gpio_export_link(struct device *dev, const char *name, | 146 | extern int gpio_export_link(struct device *dev, const char *name, |
146 | unsigned gpio); | 147 | unsigned gpio); |
148 | extern int gpio_sysfs_set_active_low(unsigned gpio, int value); | ||
147 | extern void gpio_unexport(unsigned gpio); | 149 | extern void gpio_unexport(unsigned gpio); |
148 | 150 | ||
149 | #endif /* CONFIG_GPIO_SYSFS */ | 151 | #endif /* CONFIG_GPIO_SYSFS */ |
@@ -181,6 +183,8 @@ static inline void gpio_set_value_cansleep(unsigned gpio, int value) | |||
181 | 183 | ||
182 | #ifndef CONFIG_GPIO_SYSFS | 184 | #ifndef CONFIG_GPIO_SYSFS |
183 | 185 | ||
186 | struct device; | ||
187 | |||
184 | /* sysfs support is only available with gpiolib, where it's optional */ | 188 | /* sysfs support is only available with gpiolib, where it's optional */ |
185 | 189 | ||
186 | static inline int gpio_export(unsigned gpio, bool direction_may_change) | 190 | static inline int gpio_export(unsigned gpio, bool direction_may_change) |
@@ -194,6 +198,11 @@ static inline int gpio_export_link(struct device *dev, const char *name, | |||
194 | return -ENOSYS; | 198 | return -ENOSYS; |
195 | } | 199 | } |
196 | 200 | ||
201 | static inline int gpio_sysfs_set_active_low(unsigned gpio, int value) | ||
202 | { | ||
203 | return -ENOSYS; | ||
204 | } | ||
205 | |||
197 | static inline void gpio_unexport(unsigned gpio) | 206 | static inline void gpio_unexport(unsigned gpio) |
198 | { | 207 | { |
199 | } | 208 | } |