diff options
| -rw-r--r-- | drivers/gpio/gpiolib.c | 4 | ||||
| -rw-r--r-- | include/asm-generic/gpio.h | 4 | ||||
| -rw-r--r-- | include/linux/gpio.h | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpio/gpiolib.c b/drivers/gpio/gpiolib.c index 137a8ca67822..a971e3d043ba 100644 --- a/drivers/gpio/gpiolib.c +++ b/drivers/gpio/gpiolib.c | |||
| @@ -1296,7 +1296,7 @@ EXPORT_SYMBOL_GPL(gpio_request_one); | |||
| 1296 | * @array: array of the 'struct gpio' | 1296 | * @array: array of the 'struct gpio' |
| 1297 | * @num: how many GPIOs in the array | 1297 | * @num: how many GPIOs in the array |
| 1298 | */ | 1298 | */ |
| 1299 | int gpio_request_array(struct gpio *array, size_t num) | 1299 | int gpio_request_array(const struct gpio *array, size_t num) |
| 1300 | { | 1300 | { |
| 1301 | int i, err; | 1301 | int i, err; |
| 1302 | 1302 | ||
| @@ -1319,7 +1319,7 @@ EXPORT_SYMBOL_GPL(gpio_request_array); | |||
| 1319 | * @array: array of the 'struct gpio' | 1319 | * @array: array of the 'struct gpio' |
| 1320 | * @num: how many GPIOs in the array | 1320 | * @num: how many GPIOs in the array |
| 1321 | */ | 1321 | */ |
| 1322 | void gpio_free_array(struct gpio *array, size_t num) | 1322 | void gpio_free_array(const struct gpio *array, size_t num) |
| 1323 | { | 1323 | { |
| 1324 | while (num--) | 1324 | while (num--) |
| 1325 | gpio_free((array++)->gpio); | 1325 | gpio_free((array++)->gpio); |
diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h index a98b52cb970b..fcdcb5d5c995 100644 --- a/include/asm-generic/gpio.h +++ b/include/asm-generic/gpio.h | |||
| @@ -193,8 +193,8 @@ struct gpio { | |||
| 193 | }; | 193 | }; |
| 194 | 194 | ||
| 195 | extern int gpio_request_one(unsigned gpio, unsigned long flags, const char *label); | 195 | extern int gpio_request_one(unsigned gpio, unsigned long flags, const char *label); |
| 196 | extern int gpio_request_array(struct gpio *array, size_t num); | 196 | extern int gpio_request_array(const struct gpio *array, size_t num); |
| 197 | extern void gpio_free_array(struct gpio *array, size_t num); | 197 | extern void gpio_free_array(const struct gpio *array, size_t num); |
| 198 | 198 | ||
| 199 | #ifdef CONFIG_GPIO_SYSFS | 199 | #ifdef CONFIG_GPIO_SYSFS |
| 200 | 200 | ||
diff --git a/include/linux/gpio.h b/include/linux/gpio.h index 0f8265f8e8c3..32d47e710661 100644 --- a/include/linux/gpio.h +++ b/include/linux/gpio.h | |||
| @@ -41,7 +41,7 @@ static inline int gpio_request_one(unsigned gpio, | |||
| 41 | return -ENOSYS; | 41 | return -ENOSYS; |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | static inline int gpio_request_array(struct gpio *array, size_t num) | 44 | static inline int gpio_request_array(const struct gpio *array, size_t num) |
| 45 | { | 45 | { |
| 46 | return -ENOSYS; | 46 | return -ENOSYS; |
| 47 | } | 47 | } |
| @@ -54,7 +54,7 @@ static inline void gpio_free(unsigned gpio) | |||
| 54 | WARN_ON(1); | 54 | WARN_ON(1); |
| 55 | } | 55 | } |
| 56 | 56 | ||
| 57 | static inline void gpio_free_array(struct gpio *array, size_t num) | 57 | static inline void gpio_free_array(const struct gpio *array, size_t num) |
| 58 | { | 58 | { |
| 59 | might_sleep(); | 59 | might_sleep(); |
| 60 | 60 | ||
