diff mbox

ARM: mutually exclude ZBOOT_ROM and AUTO_ZRELADDR

Message ID 1318607945-6807-1-git-send-email-olof@lixom.net
State New, archived
Headers show

Commit Message

Olof Johansson Oct. 14, 2011, 3:59 p.m. UTC
This way platforms that want it can select AUTO_ZRELADDR without issues caused by
someone manually also enabling ZBOOT_ROM.

Signed-off-by: Olof Johansson <olof@lixom.net>
---
 arch/arm/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)


Russell King wrote at Friday, October 14, 2011 1:15 AM:

> I'll point out that this makes Tegra incompatible with ZBOOT_ROM, which
> can still be enabled.  ZBOOT_ROM=y AUTO_ZRELADDR=y is an invalid
> configuration at runtime.

Ah, looks like the dependency is only one-way. Since they are mutually
exclusive, how about the below?

Comments

Arnd Bergmann Oct. 14, 2011, 4:29 p.m. UTC | #1
On Friday 14 October 2011, Olof Johansson wrote:
> This way platforms that want it can select AUTO_ZRELADDR without issues caused by
> someone manually also enabling ZBOOT_ROM.
> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> index 82973b2..2ad58e8 100644
> --- a/arch/arm/Kconfig
> +++ b/arch/arm/Kconfig
> @@ -1814,6 +1814,7 @@ config ZBOOT_ROM_BSS
>  config ZBOOT_ROM
>  	bool "Compressed boot loader in ROM/flash"
>  	depends on ZBOOT_ROM_TEXT != ZBOOT_ROM_BSS
> +	depends on !AUTO_ZRELADDR
>  	help
>  	  Say Y here if you intend to execute your compressed kernel image
>  	  (zImage) directly from ROM or flash.  If unsure, say N.

Unfortunately, you cannot have it both ways:

arnd@ocdc-kvm:~/linux-arm$ make O=obj-tmp CROSS_COMPILE=arm-linux-gnueabi- ARCH=arm  -sj20  menuconfig
arch/arm/Kconfig:1761:error: recursive dependency detected!
arch/arm/Kconfig:1761:  symbol ZBOOT_ROM depends on AUTO_ZRELADDR
arch/arm/Kconfig:1899:  symbol AUTO_ZRELADDR depends on ZBOOT_ROM

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Nicolas Pitre Oct. 14, 2011, 6:04 p.m. UTC | #2
On Fri, 14 Oct 2011, Olof Johansson wrote:

> This way platforms that want it can select AUTO_ZRELADDR without issues caused by
> someone manually also enabling ZBOOT_ROM.
> 
> Signed-off-by: Olof Johansson <olof@lixom.net>

Acked-by: Nicolas Pitre <nicolas.pitre@linaro.org>

Certainly harmless for the time being.



> ---
>  arch/arm/Kconfig |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> 
> Russell King wrote at Friday, October 14, 2011 1:15 AM:
> 
> > I'll point out that this makes Tegra incompatible with ZBOOT_ROM, which
> > can still be enabled.  ZBOOT_ROM=y AUTO_ZRELADDR=y is an invalid
> > configuration at runtime.
> 
> Ah, looks like the dependency is only one-way. Since they are mutually
> exclusive, how about the below?
> 
> 
> diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> index 82973b2..2ad58e8 100644
> --- a/arch/arm/Kconfig
> +++ b/arch/arm/Kconfig
> @@ -1814,6 +1814,7 @@ config ZBOOT_ROM_BSS
>  config ZBOOT_ROM
>  	bool "Compressed boot loader in ROM/flash"
>  	depends on ZBOOT_ROM_TEXT != ZBOOT_ROM_BSS
> +	depends on !AUTO_ZRELADDR
>  	help
>  	  Say Y here if you intend to execute your compressed kernel image
>  	  (zImage) directly from ROM or flash.  If unsure, say N.
> -- 
> 1.7.4.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Nicolas Pitre Oct. 14, 2011, 6:07 p.m. UTC | #3
On Fri, 14 Oct 2011, Arnd Bergmann wrote:

> On Friday 14 October 2011, Olof Johansson wrote:
> > This way platforms that want it can select AUTO_ZRELADDR without issues caused by
> > someone manually also enabling ZBOOT_ROM.
> > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
> > index 82973b2..2ad58e8 100644
> > --- a/arch/arm/Kconfig
> > +++ b/arch/arm/Kconfig
> > @@ -1814,6 +1814,7 @@ config ZBOOT_ROM_BSS
> >  config ZBOOT_ROM
> >  	bool "Compressed boot loader in ROM/flash"
> >  	depends on ZBOOT_ROM_TEXT != ZBOOT_ROM_BSS
> > +	depends on !AUTO_ZRELADDR
> >  	help
> >  	  Say Y here if you intend to execute your compressed kernel image
> >  	  (zImage) directly from ROM or flash.  If unsure, say N.
> 
> Unfortunately, you cannot have it both ways:
> 
> arnd@ocdc-kvm:~/linux-arm$ make O=obj-tmp CROSS_COMPILE=arm-linux-gnueabi- ARCH=arm  -sj20  menuconfig
> arch/arm/Kconfig:1761:error: recursive dependency detected!
> arch/arm/Kconfig:1761:  symbol ZBOOT_ROM depends on AUTO_ZRELADDR

Ah, right.

OK, like I said I'm reworking the whole thing, so the cheapest fix for 
the time being  is "select AUTO_ZRELADDR if !ZBOOT_ROM".


Nicolas
--
To unsubscribe from this list: send the line "unsubscribe linux-tegra" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 82973b2..2ad58e8 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -1814,6 +1814,7 @@  config ZBOOT_ROM_BSS
 config ZBOOT_ROM
 	bool "Compressed boot loader in ROM/flash"
 	depends on ZBOOT_ROM_TEXT != ZBOOT_ROM_BSS
+	depends on !AUTO_ZRELADDR
 	help
 	  Say Y here if you intend to execute your compressed kernel image
 	  (zImage) directly from ROM or flash.  If unsure, say N.