Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1437691 > unrolled thread

[PATCH] gpio: tegra: don't auto-enable for COMPILE_TEST

Started byArnd Bergmann <arnd@arndb.de>
First post2016-07-06 15:00 +0200
Last post2016-07-06 15:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] gpio: tegra: don't auto-enable for COMPILE_TEST Arnd Bergmann <arnd@arndb.de> - 2016-07-06 15:00 +0200
    Re: [PATCH] gpio: tegra: don't auto-enable for COMPILE_TEST Linus Walleij <linus.walleij@linaro.org> - 2016-07-06 15:40 +0200

#1437691 — [PATCH] gpio: tegra: don't auto-enable for COMPILE_TEST

FromArnd Bergmann <arnd@arndb.de>
Date2016-07-06 15:00 +0200
Subject[PATCH] gpio: tegra: don't auto-enable for COMPILE_TEST
Message-ID<rRUAN-Sa-13@gated-at.bofh.it>
I stumbled over a build error with COMPILE_TEST and CONFIG_OF
disabled:

drivers/gpio/gpio-tegra.c: In function 'tegra_gpio_probe':
drivers/gpio/gpio-tegra.c:603:9: error: 'struct gpio_chip' has no member named 'of_node'

The problem is that the newly added GPIO_TEGRA Kconfig symbol
does not have a dependency on CONFIG_OF. However, there is another
problem here as the driver gets enabled unconditionally whenever
COMPILE_TEST is set.

This fixes both problems, by making the symbol user-visible
when COMPILE_TEST is set and default-enabled for ARCH_TEGRA=y.

As a side-effect, it is now possible to compile-test a Tegra
kernel with GPIO support disabled, which is harmless.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Fixes: 4dd4dd1d2120 ("gpio: tegra: Allow compile test")
---
 drivers/gpio/Kconfig | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
index 681c2dcd697b..513a3d174706 100644
--- a/drivers/gpio/Kconfig
+++ b/drivers/gpio/Kconfig
@@ -402,9 +402,12 @@ config GPIO_TB10X
 	select OF_GPIO
 
 config GPIO_TEGRA
-	bool
-	default y
+	bool "NVIDIA Tegra GPIO support"
+	default ARCH_TEGRA
 	depends on ARCH_TEGRA || COMPILE_TEST
+	depends on OF
+	help
+	  Say yes here to support GPIO pins on NVIDIA Tegra SoCs.
 
 config GPIO_TS4800
 	tristate "TS-4800 DIO blocks and compatibles"
-- 
2.9.0

[toc] | [next] | [standalone]


#1437731

FromLinus Walleij <linus.walleij@linaro.org>
Date2016-07-06 15:40 +0200
Message-ID<rRVdw-1mu-29@gated-at.bofh.it>
In reply to#1437691
On Wed, Jul 6, 2016 at 2:54 PM, Arnd Bergmann <arnd@arndb.de> wrote:

> I stumbled over a build error with COMPILE_TEST and CONFIG_OF
> disabled:
>
> drivers/gpio/gpio-tegra.c: In function 'tegra_gpio_probe':
> drivers/gpio/gpio-tegra.c:603:9: error: 'struct gpio_chip' has no member named 'of_node'
>
> The problem is that the newly added GPIO_TEGRA Kconfig symbol
> does not have a dependency on CONFIG_OF. However, there is another
> problem here as the driver gets enabled unconditionally whenever
> COMPILE_TEST is set.
>
> This fixes both problems, by making the symbol user-visible
> when COMPILE_TEST is set and default-enabled for ARCH_TEGRA=y.
>
> As a side-effect, it is now possible to compile-test a Tegra
> kernel with GPIO support disabled, which is harmless.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> Fixes: 4dd4dd1d2120 ("gpio: tegra: Allow compile test")

Patch applied.

I'm starting to get a bit tired about anything related to compile testing.

It's not like I don't understand that it is good to test-build things ...

It's just that enabling this turns up so many strange compile bugs to
the left and right that it takes focus away from core development.
I don't know what can be done to alleviate the situation.

Yours,
Linus Walleij

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web