summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephen Warren <swarren@nvidia.com>2011-08-23 03:39:56 +0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2011-08-24 11:28:37 +0400
commit438a99c078b1bc3c9aebd92e7928f2477311d3e5 (patch)
tree7b55985c2f4597befc23607c246d7e1d59d2b2d7
parent470080015c1f8bbd15ba1486d5c4bd8a3e7fa79a (diff)
downloadlinux-438a99c078b1bc3c9aebd92e7928f2477311d3e5.tar.xz
ARM: 7053/1: gpio/tegra: Implement gpio_chip.to_irq
Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--drivers/gpio/gpio-tegra.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c
index ecade29d79e8..df64536464f0 100644
--- a/drivers/gpio/gpio-tegra.c
+++ b/drivers/gpio/gpio-tegra.c
@@ -134,7 +134,10 @@ static int tegra_gpio_direction_output(struct gpio_chip *chip, unsigned offset,
return 0;
}
-
+static int tegra_gpio_to_irq(struct gpio_chip *chip, unsigned offset)
+{
+ return TEGRA_GPIO_TO_IRQ(offset);
+}
static struct gpio_chip tegra_gpio_chip = {
.label = "tegra-gpio",
@@ -142,6 +145,7 @@ static struct gpio_chip tegra_gpio_chip = {
.get = tegra_gpio_get,
.direction_output = tegra_gpio_direction_output,
.set = tegra_gpio_set,
+ .to_irq = tegra_gpio_to_irq,
.base = 0,
.ngpio = TEGRA_NR_GPIOS,
};