[PATCH 2/5] gpiolib-of: staticize the pin range calls

viresh kumar viresh.kumar at linaro.org
Wed Nov 7 00:11:51 EST 2012


On 6 November 2012 20:46, Linus Walleij <linus.walleij at stericsson.com> wrote:
diff --git a/drivers/gpio/gpiolib-of.c b/drivers/gpio/gpiolib-of.c

 #ifdef CONFIG_PINCTRL
-void of_gpiochip_add_pin_range(struct gpio_chip *chip)
+static void of_gpiochip_add_pin_range(struct gpio_chip *chip)
 {
        struct device_node *np = chip->of_node;
        struct gpio_pin_range *pin_range;
@@ -254,7 +254,7 @@ void of_gpiochip_add_pin_range(struct gpio_chip *chip)
        } while (index++);
 }

-void of_gpiochip_remove_pin_range(struct gpio_chip *chip)
+static void of_gpiochip_remove_pin_range(struct gpio_chip *chip)
 {
        struct gpio_pin_range *pin_range, *tmp;

@@ -265,8 +265,8 @@ void of_gpiochip_remove_pin_range(struct gpio_chip *chip)
        }
 }
 #else
-void of_gpiochip_add_pin_range(struct gpio_chip *chip) {}
-void of_gpiochip_remove_pin_range(struct gpio_chip *chip) {}
+static void of_gpiochip_add_pin_range(struct gpio_chip *chip) {}
+static void of_gpiochip_remove_pin_range(struct gpio_chip *chip) {}

Maybe static inline??

Reviewed-by: Viresh Kumar <viresh.kumar at linaro.org>



More information about the linux-arm-kernel mailing list