]> git.karo-electronics.de Git - linux-beck.git/commitdiff
pinctrl/nomadik: !CONFIG_OF build error
authorArnd Bergmann <arnd@arndb.de>
Thu, 10 May 2012 11:39:52 +0000 (13:39 +0200)
committerLinus Walleij <linus.walleij@linaro.org>
Fri, 11 May 2012 08:33:59 +0000 (10:33 +0200)
a60b57e "drivers/gpio: gpio-nomadik: Add support for irqdomains" broke
building with CONFIG_OF_GPIO disabled.

Without this patch, building nhk8815_defconfig results in:

/home/arnd/linux-arm/drivers/gpio/gpio-nomadik.c: In function 'nmk_gpio_probe':
/home/arnd/linux-arm/drivers/gpio/gpio-nomadik.c:1238:6: error: 'struct gpio_chip' has no member named 'of_node'
make[3]: *** [drivers/gpio/gpio-nomadik.o] Error 1
make[2]: *** [drivers/gpio] Error 2
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [drivers] Error 2
make[1]: *** Waiting for unfinished jobs....
make: *** [sub-make] Error 2

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-nomadik.c

index 9b126b6d79ccc0c29c8aec9748d36bc9136ee695..1352f336844435a4dd184711d40a7d869425dbef 100644 (file)
@@ -1235,7 +1235,9 @@ static int __devinit nmk_gpio_probe(struct platform_device *dev)
        nmk_chip->lowemi = readl_relaxed(nmk_chip->addr + NMK_GPIO_LOWEMI);
        clk_disable(nmk_chip->clk);
 
+#ifdef CONFIG_OF_GPIO
        chip->of_node = np;
+#endif
 
        ret = gpiochip_add(&nmk_chip->chip);
        if (ret)