From 00c337cc68c34302fc0af2d9ac47be5c638d4a78 Mon Sep 17 00:00:00 2001 From: Bartosz Golaszewski Date: Wed, 2 Jul 2025 11:14:07 +0200 Subject: [PATCH] gpio: tpic2810: remove unneeded callbacks GPIO core can handle output-only chips that don't implement the get() and direction_input() callbacks. There's no need to provide dummy implementation of the latter in the driver so drop it. Link: https://lore.kernel.org/r/20250702-gpiochip-set-rv-gpio-round3-v1-6-0d23be74f71d@linaro.org Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-tpic2810.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/drivers/gpio/gpio-tpic2810.c b/drivers/gpio/gpio-tpic2810.c index effb7b8ff81fd..e99725bd3d63d 100644 --- a/drivers/gpio/gpio-tpic2810.c +++ b/drivers/gpio/gpio-tpic2810.c @@ -34,13 +34,6 @@ static int tpic2810_get_direction(struct gpio_chip *chip, return GPIO_LINE_DIRECTION_OUT; } -static int tpic2810_direction_input(struct gpio_chip *chip, - unsigned offset) -{ - /* This device is output only */ - return -EINVAL; -} - static int tpic2810_direction_output(struct gpio_chip *chip, unsigned offset, int value) { @@ -83,7 +76,6 @@ static const struct gpio_chip template_chip = { .label = "tpic2810", .owner = THIS_MODULE, .get_direction = tpic2810_get_direction, - .direction_input = tpic2810_direction_input, .direction_output = tpic2810_direction_output, .set = tpic2810_set, .set_multiple = tpic2810_set_multiple, -- 2.47.2