4ea4b5ae64c430a8353a7604f6fad6aa411eeab4
[openwrt/svn-archive/archive.git] / target / linux / bcm53xx / patches-3.14 / 122-bcma-gpio-use-ChipCommon-GPIO-IRQ-on-BCM47XX-arch-on.patch
1 From dfe45880e4ac50ebaa57e5f8a52b69e7e74cb7ca Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5@gmail.com>
3 Date: Sun, 21 Sep 2014 20:40:32 +0200
4 Subject: [PATCH] bcma: gpio: use ChipCommon GPIO IRQ on BCM47XX arch only
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 GPIOs can be also used on bcm53xx, however this arch requires different
10 implementation of IRQ support. It uses different IRQ number (117) and
11 different masks & acking.
12
13 Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
14 ---
15 drivers/bcma/driver_gpio.c | 4 ++--
16 1 file changed, 2 insertions(+), 2 deletions(-)
17
18 --- a/drivers/bcma/driver_gpio.c
19 +++ b/drivers/bcma/driver_gpio.c
20 @@ -76,7 +76,7 @@ static void bcma_gpio_free(struct gpio_c
21 bcma_chipco_gpio_pullup(cc, 1 << gpio, 0);
22 }
23
24 -#if IS_BUILTIN(CONFIG_BCMA_HOST_SOC)
25 +#if IS_BUILTIN(CONFIG_BCM47XX)
26 static int bcma_gpio_to_irq(struct gpio_chip *chip, unsigned gpio)
27 {
28 struct bcma_drv_cc *cc = bcma_gpio_get_cc(chip);
29 @@ -215,7 +215,7 @@ int bcma_gpio_init(struct bcma_drv_cc *c
30 chip->set = bcma_gpio_set_value;
31 chip->direction_input = bcma_gpio_direction_input;
32 chip->direction_output = bcma_gpio_direction_output;
33 -#if IS_BUILTIN(CONFIG_BCMA_HOST_SOC)
34 +#if IS_BUILTIN(CONFIG_BCM47XX)
35 chip->to_irq = bcma_gpio_to_irq;
36 #endif
37 switch (cc->core->bus->chipinfo.id) {