diff options
Diffstat (limited to 'arch/sh/include/asm/gpio.h')
-rw-r--r-- | arch/sh/include/asm/gpio.h | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/arch/sh/include/asm/gpio.h b/arch/sh/include/asm/gpio.h index 9650e7c9c39e..90673658eb14 100644 --- a/arch/sh/include/asm/gpio.h +++ b/arch/sh/include/asm/gpio.h | |||
@@ -12,6 +12,9 @@ | |||
12 | #ifndef __ASM_SH_GPIO_H | 12 | #ifndef __ASM_SH_GPIO_H |
13 | #define __ASM_SH_GPIO_H | 13 | #define __ASM_SH_GPIO_H |
14 | 14 | ||
15 | #include <linux/kernel.h> | ||
16 | #include <linux/errno.h> | ||
17 | |||
15 | #if defined(CONFIG_CPU_SH3) | 18 | #if defined(CONFIG_CPU_SH3) |
16 | #include <cpu/gpio.h> | 19 | #include <cpu/gpio.h> |
17 | #endif | 20 | #endif |
@@ -62,6 +65,7 @@ struct pinmux_data_reg { | |||
62 | struct pinmux_range { | 65 | struct pinmux_range { |
63 | pinmux_enum_t begin; | 66 | pinmux_enum_t begin; |
64 | pinmux_enum_t end; | 67 | pinmux_enum_t end; |
68 | pinmux_enum_t force; | ||
65 | }; | 69 | }; |
66 | 70 | ||
67 | struct pinmux_info { | 71 | struct pinmux_info { |
@@ -99,9 +103,20 @@ int gpio_direction_input(unsigned gpio); | |||
99 | int gpio_direction_output(unsigned gpio, int value); | 103 | int gpio_direction_output(unsigned gpio, int value); |
100 | int gpio_get_value(unsigned gpio); | 104 | int gpio_get_value(unsigned gpio); |
101 | void gpio_set_value(unsigned gpio, int value); | 105 | void gpio_set_value(unsigned gpio, int value); |
102 | static inline int gpio_export(unsigned gpio, bool direction_may_change) | 106 | |
107 | /* IRQ modes are unspported */ | ||
108 | static inline int gpio_to_irq(unsigned gpio) | ||
109 | { | ||
110 | WARN_ON(1); | ||
111 | return -EINVAL; | ||
112 | } | ||
113 | |||
114 | static inline int irq_to_gpio(unsigned irq) | ||
103 | { | 115 | { |
104 | return 0; | 116 | WARN_ON(1); |
117 | return -EINVAL; | ||
105 | } | 118 | } |
106 | 119 | ||
120 | #include <asm-generic/gpio.h> | ||
121 | |||
107 | #endif /* __ASM_SH_GPIO_H */ | 122 | #endif /* __ASM_SH_GPIO_H */ |