bcm53xx: fix bcma gpio chip base
[openwrt.git] / target / linux / bcm53xx / patches-3.18 / 180-bcma_set_gpio_base.patch
1 Subject: [PATCH] bcma: set gpio chip->base for CONFIG_ARCH_BCM_5301X like on 47xx
2
3 Signed-off-by: Felix Fietkau <nbd@openwrt.org>
4 ---
5 --- a/drivers/bcma/driver_gpio.c
6 +++ b/drivers/bcma/driver_gpio.c
7 @@ -240,7 +240,7 @@ int bcma_gpio_init(struct bcma_drv_cc *c
8          * relative (per chip) numbers.
9          * So let's use predictable base for BCM47XX and "random" for all other.
10          */
11 -#if IS_BUILTIN(CONFIG_BCM47XX)
12 +#if IS_BUILTIN(CONFIG_BCM47XX) || IS_BUILTIN(CONFIG_ARCH_BCM_5301X)
13         chip->base              = bus->num * BCMA_GPIO_MAX_PINS;
14  #else
15         chip->base              = -1;