Re: [PATCH] MIPS: Remove most of the custom gpio.h
From: Linus Walleij <hidden>
Date: 2015-07-27 13:20:11
Also in:
linux-gpio, linux-ide, linux-input, linux-mips, lkml
From: Linus Walleij <hidden>
Date: 2015-07-27 13:20:11
Also in:
linux-gpio, linux-ide, linux-input, linux-mips, lkml
On Thu, Jul 23, 2015 at 8:25 PM, Lars-Peter Clausen [off-list ref] wrote:
On 07/22/2015 07:33 PM, Alban Bedel wrote:quoted
diff --git a/arch/mips/jz4740/gpio.c b/arch/mips/jz4740/gpio.c index 54c80d4..3dc500c 100644 --- a/arch/mips/jz4740/gpio.c +++ b/arch/mips/jz4740/gpio.c@@ -262,18 +262,6 @@ uint32_t jz_gpio_port_get_value(int port, uint32_tmask) } EXPORT_SYMBOL(jz_gpio_port_get_value); -int gpio_to_irq(unsigned gpio) -{ - return JZ4740_IRQ_GPIO(0) + gpio; -} -EXPORT_SYMBOL_GPL(gpio_to_irq);This need to be hooked up the gpio_to_irq() callback of the gpio_chip struct of this driver rather than completely removing it. Otherwise this functionality will be broken. Similar for other platforms which implement the function.
Even better is to see if we can convert the driver to GPIOLIB_IRQCHIP which moves the handling of IRQ mapping to the gpiolib core. This works for all simple cascading GPIO-with-IRQ controllers with a local mask register. (Not when the system intcon and GPIO is mashed up though.) But no hurry with that. Yours, Linus Walleij