Skip to contentSkip to conversation

ARM: merge commonly-defined PLATFORM_RELFLAGS

PATCH Superseded Masahiro Yamada 2 participants 3 messages Nov 14, 2013 – Jan 15, 2014 Arm (32-bit)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: merge commonly-defined PLATFORM_RELFLAGS

All arch/arm/cpu/${CPU}/config.mk had the same
PLATFORM_RELFLAGS definitions.
This commit merges them into arch/arm/config.mk.

---
 arch/arm/config.mk               | 4 +++-
 arch/arm/cpu/arm1136/config.mk   | 7 -------
 arch/arm/cpu/arm1176/config.mk   | 8 --------
 arch/arm/cpu/arm720t/config.mk   | 8 --------
 arch/arm/cpu/arm920t/config.mk   | 7 -------
 arch/arm/cpu/arm926ejs/config.mk | 7 -------
 arch/arm/cpu/arm946es/config.mk  | 7 -------
 arch/arm/cpu/arm_intcm/config.mk | 7 -------
 arch/arm/cpu/armv7/config.mk     | 8 --------
 arch/arm/cpu/ixp/config.mk       | 8 --------
 arch/arm/cpu/pxa/config.mk       | 7 -------
 arch/arm/cpu/sa1100/config.mk    | 7 -------
 12 files changed, 3 insertions(+), 82 deletions(-)
arch/arm/config.mk +3 -1
index bdabcf4..e2ff323 100644
@@ -17,7 +17,9 @@ endif
 
 LDFLAGS_FINAL += --gc-sections
 PLATFORM_RELFLAGS += -ffunction-sections -fdata-sections \
-		     -fno-common -ffixed-r9 -msoft-float
+		     -fno-common -ffixed-r9 -msoft-float \
+		     $(call cc-option,-mshort-load-bytes,\
+		     $(call cc-option,-malignment-traps,))
 
 # Support generic board on ARM
 __HAVE_ARCH_GENERIC_BOARD := y
arch/arm/cpu/arm1136/config.mk +0 -7
index b4d396d..f74228c 100644
@@ -7,13 +7,6 @@
 
 # Make ARMv5 to allow more compilers to work, even though its v6.
 PLATFORM_CPPFLAGS += -march=armv5
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
 
 ifneq ($(CONFIG_IMX_CONFIG),)
 ifdef CONFIG_SPL
arch/arm/cpu/arm1176/config.mk +0 -8
index f4631cb..5dc2ebb 100644
@@ -7,11 +7,3 @@
 
 # Make ARMv5 to allow more compilers to work, even though its v6.
 PLATFORM_CPPFLAGS += -march=armv5t
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,\
-			$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/arm720t/config.mk +0 -8
index 2581f0a..772fb41 100644
@@ -7,11 +7,3 @@
 #
 
 PLATFORM_CPPFLAGS += -march=armv4 -mtune=arm7tdmi
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,\
-			$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/arm920t/config.mk +0 -7
index 67537dc..799afff 100644
@@ -6,10 +6,3 @@
 #
 
 PLATFORM_CPPFLAGS += -march=armv4
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/arm926ejs/config.mk +0 -7
index 12b0d09..4d9895f 100644
@@ -6,13 +6,6 @@
 #
 
 PLATFORM_CPPFLAGS += -march=armv5te
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
 
 ifneq ($(CONFIG_IMX_CONFIG),)
 ifdef CONFIG_SPL
arch/arm/cpu/arm946es/config.mk +0 -7
index eb81a57..438668d 100644
@@ -6,10 +6,3 @@
 #
 
 PLATFORM_CPPFLAGS +=  -march=armv4
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/arm_intcm/config.mk +0 -7
index eb81a57..438668d 100644
@@ -6,10 +6,3 @@
 #
 
 PLATFORM_CPPFLAGS +=  -march=armv4
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/armv7/config.mk +0 -8
index f0d9c04..38b7c40 100644
@@ -10,14 +10,6 @@
 PF_CPPFLAGS_ARMV7 := $(call cc-option, -march=armv7-a, -march=armv5)
 PLATFORM_CPPFLAGS += $(PF_CPPFLAGS_ARMV7)
 
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
-
 # SEE README.arm-unaligned-accesses
 PF_NO_UNALIGNED := $(call cc-option, -mno-unaligned-access,)
 PLATFORM_NO_UNALIGNED := $(PF_NO_UNALIGNED)
arch/arm/cpu/ixp/config.mk +0 -8
index fd47c60..894861f 100644
@@ -14,11 +14,3 @@ PLATFORM_CPPFLAGS += -mbig-endian -march=armv5te -mtune=strongarm1100
 
 PLATFORM_LDFLAGS += -EB
 USE_PRIVATE_LIBGCC = yes
-
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# =========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/pxa/config.mk +0 -7
index d8d263d..f09f3c5 100644
@@ -7,10 +7,3 @@
 #
 
 PLATFORM_CPPFLAGS += -mcpu=xscale
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# ========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
arch/arm/cpu/sa1100/config.mk +0 -7
index b3026cc..3afa685 100644
@@ -7,10 +7,3 @@
 #
 
 PLATFORM_CPPFLAGS += -march=armv4 -mtune=strongarm1100
-# =========================================================================
-#
-# Supply options according to compiler version
-#
-# ========================================================================
-PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
-PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
Signature · 1 line
1.8.3.2
#1 lore raw

PATCH 1/1 ARM: merge commonly-defined PLATFORM_RELFLAGS

Hi Masahiro,

Quoted 6 lines · Masahiro Yamada

All arch/arm/cpu/${CPU}/config.mk had the same
PLATFORM_RELFLAGS definitions.
This commit merges them into arch/arm/config.mk.

---

This does not apply cleanly on ARM tree. Can you please rebase and submit v2?

Amicalement,

Signature · 1 line
Albert.