From: Quanyang Wang <quanyang.w...@windriver.com> When CONFIG_CPU_32v6 is enabled and arm gcc isn't configured with the option "--with-arch=armv7-a", there will be a build error message as below:
arch/arm/mach-zynq/suspend.S:68: Error: selected processor does not support `dsb sy' in ARM mode arch/arm/mach-zynq/headsmp.S:13: Error: selected processor does not support `setend be' in ARM mode This is because in arch/arm/Makefile, arch-$(CONFIG_CPU_32v6) will override arch-$(CONFIG_CPU_32v7), and if the arm gcc doesn't contain "--with-arch=armv7-a" feature, gcc can only handle armv6 instructions and armv7 instructions in suspend.S and headsmp.S can't be recognized. Let's add "-march=armv7-a" to AFLAGS explicitly to avoid this build error. Reported-by: kernel test robot <l...@intel.com> Signed-off-by: Quanyang Wang <quanyang.w...@windriver.com> --- arch/arm/mach-zynq/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/mach-zynq/Makefile b/arch/arm/mach-zynq/Makefile index dbb75be53deb..9b3e6a4140a2 100644 --- a/arch/arm/mach-zynq/Makefile +++ b/arch/arm/mach-zynq/Makefile @@ -10,3 +10,5 @@ obj-$(CONFIG_SMP) += headsmp.o platsmp.o ORIG_AFLAGS := $(KBUILD_AFLAGS) KBUILD_AFLAGS = $(subst -march=armv6k,,$(ORIG_AFLAGS)) obj-$(CONFIG_SUSPEND) += suspend.o +AFLAGS_suspend.o +=-Wa,-march=armv7-a +AFLAGS_headsmp.o +=-Wa,-march=armv7-a -- 2.25.1
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#9803): https://lists.yoctoproject.org/g/linux-yocto/message/9803 Mute This Topic: https://lists.yoctoproject.org/mt/82303755/21656 Group Owner: linux-yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-