memory: omap-gpmc: remove GPIO set() and direction_output() callbacks
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Mon, 7 Apr 2025 07:21:20 +0000 (09:21 +0200)
committerKrzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Tue, 15 Apr 2025 05:43:35 +0000 (07:43 +0200)
This driver implements an input-only GPIO controller. There's no need to
implement the set() and direction_output() callbacks in this case, the
GPIO core will handle it.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Link: https://lore.kernel.org/r/20250407-gpiochip-set-rv-memory-v1-2-5ab0282a9da7@linaro.org
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
drivers/memory/omap-gpmc.c

index d4fe4c5a57e7a9d4243eba8790c9b479fb15cd9f..a61e71c31f200912ece41281de370ebac893df5c 100644 (file)
@@ -2385,17 +2385,6 @@ static int gpmc_gpio_direction_input(struct gpio_chip *chip,
        return 0;       /* we're input only */
 }
 
-static int gpmc_gpio_direction_output(struct gpio_chip *chip,
-                                     unsigned int offset, int value)
-{
-       return -EINVAL; /* we're input only */
-}
-
-static void gpmc_gpio_set(struct gpio_chip *chip, unsigned int offset,
-                         int value)
-{
-}
-
 static int gpmc_gpio_get(struct gpio_chip *chip, unsigned int offset)
 {
        u32 reg;
@@ -2417,8 +2406,6 @@ static int gpmc_gpio_init(struct gpmc_device *gpmc)
        gpmc->gpio_chip.ngpio = gpmc_nr_waitpins;
        gpmc->gpio_chip.get_direction = gpmc_gpio_get_direction;
        gpmc->gpio_chip.direction_input = gpmc_gpio_direction_input;
-       gpmc->gpio_chip.direction_output = gpmc_gpio_direction_output;
-       gpmc->gpio_chip.set = gpmc_gpio_set;
        gpmc->gpio_chip.get = gpmc_gpio_get;
        gpmc->gpio_chip.base = -1;