1 --- a/arch/mips/bcm47xx/gpio.c
2 +++ b/arch/mips/bcm47xx/gpio.c
6 #include <linux/export.h>
7 +#include <linux/gpio.h>
8 #include <linux/ssb/ssb.h>
9 #include <linux/ssb/ssb_driver_chipcommon.h>
10 #include <linux/ssb/ssb_driver_extif.h>
11 @@ -100,3 +101,30 @@ int gpio_to_irq(unsigned gpio)
14 EXPORT_SYMBOL_GPL(gpio_to_irq);
17 + * gpio_request_one - request a single GPIO with initial configuration
18 + * @gpio: the GPIO number
19 + * @flags: GPIO configuration as specified by GPIOF_*
20 + * @label: a literal description string of this GPIO
22 +int gpio_request_one(unsigned gpio, unsigned long flags, const char *label)
26 + err = gpio_request(gpio, label);
30 + if (flags & GPIOF_DIR_IN)
31 + err = gpio_direction_input(gpio);
33 + err = gpio_direction_output(gpio,
34 + (flags & GPIOF_INIT_HIGH) ? 1 : 0);
41 +EXPORT_SYMBOL_GPL(gpio_request_one);
42 --- a/arch/mips/include/asm/mach-bcm47xx/gpio.h
43 +++ b/arch/mips/include/asm/mach-bcm47xx/gpio.h
45 extern int gpio_request(unsigned gpio, const char *label);
46 extern void gpio_free(unsigned gpio);
47 extern int gpio_to_irq(unsigned gpio);
48 +extern int gpio_request_one(unsigned gpio, unsigned long flags, const char *label);
50 static inline int gpio_get_value(unsigned gpio)