summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2023-01-12 16:39:42 +0300
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>2023-01-30 17:55:29 +0300
commita5ec171efdc6151d3a51c4e1a59abb3ab9d8b710 (patch)
tree34c2decc74b958375d87c37c330e90e74eba9bbe /arch
parent029d14e900e7766eb2330bd4912dc28c0466db06 (diff)
downloadlinux-a5ec171efdc6151d3a51c4e1a59abb3ab9d8b710.tar.xz
gpio: Remove unused and obsoleted irq_to_gpio()
irq_to_gpio() is legacy and unused API, remove it for good. This leaves gpio_to_irq() as it's used yet in many places. Nevertheless, removal of its counterpart is a good signal to whoever even trying to consider using them that do not. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/m68k/include/asm/gpio.h7
-rw-r--r--arch/sh/include/asm/gpio.h5
2 files changed, 0 insertions, 12 deletions
diff --git a/arch/m68k/include/asm/gpio.h b/arch/m68k/include/asm/gpio.h
index a50b27719a58..5cfc0996ba94 100644
--- a/arch/m68k/include/asm/gpio.h
+++ b/arch/m68k/include/asm/gpio.h
@@ -66,13 +66,6 @@ static inline int gpio_to_irq(unsigned gpio)
return __gpio_to_irq(gpio);
}
-static inline int irq_to_gpio(unsigned irq)
-{
- return (irq >= MCFGPIO_IRQ_VECBASE &&
- irq < (MCFGPIO_IRQ_VECBASE + MCFGPIO_IRQ_MAX)) ?
- irq - MCFGPIO_IRQ_VECBASE : -ENXIO;
-}
-
static inline int gpio_cansleep(unsigned gpio)
{
return gpio < MCFGPIO_PIN_MAX ? 0 : __gpio_cansleep(gpio);
diff --git a/arch/sh/include/asm/gpio.h b/arch/sh/include/asm/gpio.h
index d643250f0a0f..588c1380e4cb 100644
--- a/arch/sh/include/asm/gpio.h
+++ b/arch/sh/include/asm/gpio.h
@@ -40,11 +40,6 @@ static inline int gpio_to_irq(unsigned gpio)
return __gpio_to_irq(gpio);
}
-static inline int irq_to_gpio(unsigned int irq)
-{
- return -ENOSYS;
-}
-
#endif /* CONFIG_GPIOLIB */
#endif /* __ASM_SH_GPIO_H */