summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorAndi Kleen2012-03-28 20:51:17 +0200
committerH. Peter Anvin2012-03-30 19:06:39 +0200
commitc0e9afc0da6cb0f11497e5ea83377b3c451450e0 (patch)
tree37d6e2f3771b86bbfa12b7a534ebc8f96950493e /arch
parentx86: Remove the ancient and deprecated disable_hlt() and enable_hlt() facility (diff)
downloadkernel-qcow2-linux-c0e9afc0da6cb0f11497e5ea83377b3c451450e0.tar.gz
kernel-qcow2-linux-c0e9afc0da6cb0f11497e5ea83377b3c451450e0.tar.xz
kernel-qcow2-linux-c0e9afc0da6cb0f11497e5ea83377b3c451450e0.zip
x86: Use -mno-avx when available
On gccs that support AVX it's a good idea to disable that too, similar to how SSE2, SSE1 etc. are already disabled. This prevents the compiler from generating AVX ever implicitely. No failure observed, just from review. [ hpa: Marking this for urgent and stable, simply because the patch will either have absolutely no effect *or* it will avoid potentially very hard to debug failures. ] Signed-off-by: Andi Kleen <ak@linux.intel.com> Link: http://lkml.kernel.org/r/1332960678-11879-1-git-send-email-andi@firstfloor.org Signed-off-by: H. Peter Anvin <hpa@zytor.com> Cc: <stable@vger.kernel.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/Makefile1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/x86/Makefile b/arch/x86/Makefile
index 968dbe24a255..41a7237606a3 100644
--- a/arch/x86/Makefile
+++ b/arch/x86/Makefile
@@ -129,6 +129,7 @@ KBUILD_CFLAGS += -Wno-sign-compare
KBUILD_CFLAGS += -fno-asynchronous-unwind-tables
# prevent gcc from generating any FP code by mistake
KBUILD_CFLAGS += $(call cc-option,-mno-sse -mno-mmx -mno-sse2 -mno-3dnow,)
+KBUILD_CFLAGS += $(call cc-option,-mno-avx,)
KBUILD_CFLAGS += $(mflags-y)
KBUILD_AFLAGS += $(mflags-y)