diff mbox

[11/12] ARM: initial multiplatform support

Message ID 201209121949.49109.arnd@arndb.de (mailing list archive)
State New, archived
Headers show

Commit Message

Arnd Bergmann Sept. 12, 2012, 7:49 p.m. UTC
On Thursday 06 September 2012, Rob Herring wrote:

> +machine-$(CONFIG_ARCH_EXYNOS4)         += exynos
> +machine-$(CONFIG_ARCH_EXYNOS5)         += exynos

> +machine-$(CONFIG_MACH_SPEAR1310)       += spear13xx
> +machine-$(CONFIG_MACH_SPEAR1340)       += spear13xx

> +machine-$(CONFIG_MACH_SPEAR300)                += spear3xx
> +machine-$(CONFIG_MACH_SPEAR310)                += spear3xx

> +machine-$(CONFIG_MACH_SPEAR320)                += spear3xx
> +machine-$(CONFIG_MACH_SPEAR600)                += spear6xx

I did a little bit of testing and got this message:

/home/arnd/linux-arm/Makefile:774: target `arch/arm/mach-spear13xx' given more than once in the same rule.
arch/arm/mach-spear13xx/built-in.o:(.init.data+0x0): multiple definition of `spear13xx_smp_ops'
arch/arm/mach-spear13xx/built-in.o:(.init.data+0x0): first defined here

The patch below ensures that each machine is only listed once.
Please fold this into your patch.

	Arnd

Comments

Rob Herring Sept. 12, 2012, 8:20 p.m. UTC | #1
On 09/12/2012 02:49 PM, Arnd Bergmann wrote:
> On Thursday 06 September 2012, Rob Herring wrote:
> 
>> +machine-$(CONFIG_ARCH_EXYNOS4)         += exynos
>> +machine-$(CONFIG_ARCH_EXYNOS5)         += exynos
> 
>> +machine-$(CONFIG_MACH_SPEAR1310)       += spear13xx
>> +machine-$(CONFIG_MACH_SPEAR1340)       += spear13xx
> 
>> +machine-$(CONFIG_MACH_SPEAR300)                += spear3xx
>> +machine-$(CONFIG_MACH_SPEAR310)                += spear3xx
> 
>> +machine-$(CONFIG_MACH_SPEAR320)                += spear3xx
>> +machine-$(CONFIG_MACH_SPEAR600)                += spear6xx
> 
> I did a little bit of testing and got this message:
> 
> /home/arnd/linux-arm/Makefile:774: target `arch/arm/mach-spear13xx' given more than once in the same rule.
> arch/arm/mach-spear13xx/built-in.o:(.init.data+0x0): multiple definition of `spear13xx_smp_ops'
> arch/arm/mach-spear13xx/built-in.o:(.init.data+0x0): first defined here
> 
> The patch below ensures that each machine is only listed once.
> Please fold this into your patch.
> 
> 	Arnd
> 
> diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> index 32a6485..ff5fb29 100644
> --- a/arch/arm/Makefile
> +++ b/arch/arm/Makefile
> @@ -233,7 +233,7 @@ ifeq ($(CONFIG_ARCH_MULTIPLATFORM),y)
>  MACHINE  :=
>  endif
>  
> -machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
> +machdirs := $(sort $(patsubst %,arch/arm/mach-%/,$(machine-y)))
>  platdirs := $(patsubst %,arch/arm/plat-%/,$(plat-y))
>  
>  ifneq ($(CONFIG_ARCH_MULTIPLATFORM),y)

Found this one as well. My fix is to use CONFIG_ARCH_EXYNOS,
CONFIG_ARCH_SPEAR3XX, etc. instead and remove the multiple lines.

I want to get this into -next and plan to send you a pull request soon.
Are you happy with the kconfig parts?

Rob
Arnd Bergmann Sept. 12, 2012, 8:27 p.m. UTC | #2
On Wednesday 12 September 2012, Rob Herring wrote:
> Found this one as well. My fix is to use CONFIG_ARCH_EXYNOS,
> CONFIG_ARCH_SPEAR3XX, etc. instead and remove the multiple lines.
> 
> I want to get this into -next and plan to send you a pull request soon.
> Are you happy with the kconfig parts?

Yes, it all looks good to me. Just doing test builds with your branch
combined with my platform data branch and Marc's smp operations.

I found a few small bugs in my patches as well.

	Arnd
diff mbox

Patch

diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 32a6485..ff5fb29 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -233,7 +233,7 @@  ifeq ($(CONFIG_ARCH_MULTIPLATFORM),y)
 MACHINE  :=
 endif
 
-machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
+machdirs := $(sort $(patsubst %,arch/arm/mach-%/,$(machine-y)))
 platdirs := $(patsubst %,arch/arm/plat-%/,$(plat-y))
 
 ifneq ($(CONFIG_ARCH_MULTIPLATFORM),y)