[source] target.mk: rework arm architecture level detection

LEDE Commits lede-commits at lists.infradead.org
Fri Jul 15 05:20:02 PDT 2016


nbd pushed a commit to source.git, branch master:
https://git.lede-project.org/?p=source.git;a=commitdiff;h=11d496d1562084d4cdd5822d5ef8fc8c176233ea

commit 11d496d1562084d4cdd5822d5ef8fc8c176233ea
Author: Felix Fietkau <nbd at nbd.name>
AuthorDate: Thu Jul 14 15:41:22 2016 +0200

    target.mk: rework arm architecture level detection
    
    Use kernel config as input instead of -march CFLAGS.
    With this change, -march can be dropped and replaced with more specific
    optimization flags for better code generation.
    
    Signed-off-by: Felix Fietkau <nbd at nbd.name>
---
 include/target.mk | 2 +-
 target/Config.in  | 6 ------
 2 files changed, 1 insertion(+), 7 deletions(-)

diff --git a/include/target.mk b/include/target.mk
index b5153ff..0a42411 100644
--- a/include/target.mk
+++ b/include/target.mk
@@ -259,7 +259,7 @@ ifeq ($(DUMP),1)
     ifneq ($(CONFIG_RTC_CLASS),)
       FEATURES += rtc
     endif
-    FEATURES += $(foreach v,v4 v5 v6 v7,$(if $(filter -march=arm$(v)%,$(CPU_CFLAGS_$(CPU_TYPE))),arm_$(v)))
+    FEATURES += $(foreach v,6 7,$(if $(CONFIG_CPU_V$(v)),arm_v$(v)))
 
     # remove duplicates
     FEATURES:=$(sort $(FEATURES))
diff --git a/target/Config.in b/target/Config.in
index 6a29d53..ee92814 100644
--- a/target/Config.in
+++ b/target/Config.in
@@ -117,12 +117,6 @@ config armeb
 	select BIG_ENDIAN
 	bool
 
-config arm_v4
-	bool
-
-config arm_v5
-	bool
-
 config arm_v6
 	bool
 



More information about the lede-commits mailing list