diff options
author | Vineet Gupta <vgupta@synopsys.com> | 2015-06-18 13:54:01 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-08-10 12:21:52 -0700 |
commit | bad8eab06cbce7ef086e60a5e5dff3923f831d61 (patch) | |
tree | 609435f5ae77d7a3adfbf7879189f777152fc15f /arch/arc | |
parent | a2bfecc423b5f96bbf9d5acb22fbceea084cc2d5 (diff) |
ARC: Override toplevel default -O2 with -O3
commit 97709069214eb75312c14946803b9da4d3814203 upstream.
ARC kernels have historically been built with -O3, despite top level
Makefile defaulting to -O2. This was facilitated by implicitly ordering
of arch makefile include AFTER top level assigned -O2.
An upstream fix to top level a1c48bb160f ("Makefile: Fix unrecognized
cross-compiler command line options") changed the ordering, making ARC
-O3 defunct.
Fix that by NOT relying on any ordering whatsoever and use the proper
arch override facility now present in kbuild (ARCH_*FLAGS)
Depends-on: ("kbuild: Allow arch Makefiles to override {cpp,ld,c}flags")
Suggested-by: Michal Marek <mmarek@suse.cz>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/arc')
-rw-r--r-- | arch/arc/Makefile | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/arc/Makefile b/arch/arc/Makefile index db72fec0e160..2f21e1e0ecf7 100644 --- a/arch/arc/Makefile +++ b/arch/arc/Makefile @@ -43,7 +43,8 @@ endif ifndef CONFIG_CC_OPTIMIZE_FOR_SIZE # Generic build system uses -O2, we want -O3 -cflags-y += -O3 +# Note: No need to add to cflags-y as that happens anyways +ARCH_CFLAGS += -O3 endif # small data is default for elf32 tool-chain. If not usable, disable it |