Re: [U-Boot] [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm compatibility
Hi Tom, > -Original Message- > From: Tom Rini [mailto:tr...@konsulko.com] > Sent: Thursday, June 08, 2017 5:12 PM > To: Vikas MANOCHA> Cc: Phil Edworthy ; Albert Aribaud > ; Kamil Lulko > ; u-boot@lists.denx.de > Subject: Re: [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm > compatibility > > On Fri, Jun 09, 2017 at 12:07:40AM +, Vikas MANOCHA wrote: > > > Hi Albert/Tom, > > > > > -Original Message- > > > From: Phil Edworthy [mailto:phil.edwor...@renesas.com] > > > Sent: Wednesday, May 31, 2017 11:33 PM > > > To: Albert Aribaud > > > Cc: Tom Rini ; Vikas MANOCHA > > > ; Kamil Lulko ; u- > > > b...@lists.denx.de; Phil Edworthy > > > Subject: [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm > > > compatibility > > > > > > Rather than change asm files that come from Linux, add the symbols > > > to Kconfig. Since one of the symbols is for thumb2 builds, make CPU_V7M > > > always select them. > > > > > > Signed-off-by: Phil Edworthy > > > --- > > > arch/arm/Kconfig | 10 ++ > > > arch/arm/lib/Makefile | 2 -- > > > 2 files changed, 10 insertions(+), 2 deletions(-) > > > > > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index > > > 2a3a36e..2793651 100644 > > > --- a/arch/arm/Kconfigl > > > +++ b/arch/arm/Kconfig > > > @@ -19,6 +19,15 @@ config HAS_VBAR > > > config HAS_THUMB2 > > > bool > > > > > > +# Used for compatibility with asm files copied from the kernel > > > +config ARM_ASM_UNIFIED > > > + bool > > > + default y > > > > Is every arm arch (arm720, arm926 etc) assembly code written for unified ? > > Otherwise we might have run-time side effects. > > I could be missing something, but this is only used by and > in turn only by arch/arm/lib/*.S, where we already had > been defining this. Yes, you are right. I was under the impression that asm/assembler.h is being used by all arm archs everywhere like startup code, cache mgt etc. Cheers, Vikas > > -- > Tom ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm compatibility
Hi Albert/Tom, > -Original Message- > From: Phil Edworthy [mailto:phil.edwor...@renesas.com] > Sent: Wednesday, May 31, 2017 11:33 PM > To: Albert Aribaud> Cc: Tom Rini ; Vikas MANOCHA ; > Kamil Lulko ; u- > b...@lists.denx.de; Phil Edworthy > Subject: [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm compatibility > > Rather than change asm files that come from Linux, add the symbols to > Kconfig. Since one of the symbols is for thumb2 builds, make > CPU_V7M always select them. > > Signed-off-by: Phil Edworthy > --- > arch/arm/Kconfig | 10 ++ > arch/arm/lib/Makefile | 2 -- > 2 files changed, 10 insertions(+), 2 deletions(-) > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 2a3a36e..2793651 100644 > --- a/arch/arm/Kconfigl > +++ b/arch/arm/Kconfig > @@ -19,6 +19,15 @@ config HAS_VBAR > config HAS_THUMB2 > bool > > +# Used for compatibility with asm files copied from the kernel config > +ARM_ASM_UNIFIED > + bool > + default y Is every arm arch (arm720, arm926 etc) assembly code written for unified ? Otherwise we might have run-time side effects. Cheers, Vikas > + > +# Used for compatibility with asm files copied from the kernel config > +THUMB2_KERNEL > + bool > + > # If set, the workarounds for these ARM errata are applied early during > U-Boot # startup. Note that in general these options force > the workarounds to be # applied; no CPU-type/version detection exists, > unlike the similar options in @@ -128,6 +137,7 @@ config > CPU_V7 config CPU_V7M > bool > select HAS_THUMB2 > + select THUMB2_KERNEL > select SYS_CACHE_SHIFT_5 > > config CPU_PXA > diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile index > f162c14..6e1c436 100644 > --- a/arch/arm/lib/Makefile > +++ b/arch/arm/lib/Makefile > @@ -72,8 +72,6 @@ ifneq (,$(findstring > -mabi=aapcs-linux,$(PLATFORM_CPPFLAGS))) > extra-y += eabi_compat.o > endif > > -asflags-y += -DCONFIG_ARM_ASM_UNIFIED > - > # some files can only build in ARM or THUMB2, not THUMB1 > > ifdef CONFIG_$(SPL_)SYS_THUMB_BUILD > -- > 2.7.4 ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
Re: [U-Boot] [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm compatibility
On Fri, Jun 09, 2017 at 12:07:40AM +, Vikas MANOCHA wrote: > Hi Albert/Tom, > > > -Original Message- > > From: Phil Edworthy [mailto:phil.edwor...@renesas.com] > > Sent: Wednesday, May 31, 2017 11:33 PM > > To: Albert Aribaud> > Cc: Tom Rini ; Vikas MANOCHA ; > > Kamil Lulko ; u- > > b...@lists.denx.de; Phil Edworthy > > Subject: [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm > > compatibility > > > > Rather than change asm files that come from Linux, add the symbols to > > Kconfig. Since one of the symbols is for thumb2 builds, make > > CPU_V7M always select them. > > > > Signed-off-by: Phil Edworthy > > --- > > arch/arm/Kconfig | 10 ++ > > arch/arm/lib/Makefile | 2 -- > > 2 files changed, 10 insertions(+), 2 deletions(-) > > > > diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 2a3a36e..2793651 > > 100644 > > --- a/arch/arm/Kconfigl > > +++ b/arch/arm/Kconfig > > @@ -19,6 +19,15 @@ config HAS_VBAR > > config HAS_THUMB2 > > bool > > > > +# Used for compatibility with asm files copied from the kernel config > > +ARM_ASM_UNIFIED > > + bool > > + default y > > Is every arm arch (arm720, arm926 etc) assembly code written for unified ? > Otherwise we might have run-time side effects. I could be missing something, but this is only used by and in turn only by arch/arm/lib/*.S, where we already had been defining this. -- Tom signature.asc Description: Digital signature ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot
[U-Boot] [PATCH 1/2] arm: Add Kconfig symbols used for Linux asm compatibility
Rather than change asm files that come from Linux, add the symbols to Kconfig. Since one of the symbols is for thumb2 builds, make CPU_V7M always select them. Signed-off-by: Phil Edworthy--- arch/arm/Kconfig | 10 ++ arch/arm/lib/Makefile | 2 -- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 2a3a36e..2793651 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -19,6 +19,15 @@ config HAS_VBAR config HAS_THUMB2 bool +# Used for compatibility with asm files copied from the kernel +config ARM_ASM_UNIFIED + bool + default y + +# Used for compatibility with asm files copied from the kernel +config THUMB2_KERNEL + bool + # If set, the workarounds for these ARM errata are applied early during U-Boot # startup. Note that in general these options force the workarounds to be # applied; no CPU-type/version detection exists, unlike the similar options in @@ -128,6 +137,7 @@ config CPU_V7 config CPU_V7M bool select HAS_THUMB2 + select THUMB2_KERNEL select SYS_CACHE_SHIFT_5 config CPU_PXA diff --git a/arch/arm/lib/Makefile b/arch/arm/lib/Makefile index f162c14..6e1c436 100644 --- a/arch/arm/lib/Makefile +++ b/arch/arm/lib/Makefile @@ -72,8 +72,6 @@ ifneq (,$(findstring -mabi=aapcs-linux,$(PLATFORM_CPPFLAGS))) extra-y+= eabi_compat.o endif -asflags-y += -DCONFIG_ARM_ASM_UNIFIED - # some files can only build in ARM or THUMB2, not THUMB1 ifdef CONFIG_$(SPL_)SYS_THUMB_BUILD -- 2.7.4 ___ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot