aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/include/asm/cpu-features.h
diff options
context:
space:
mode:
authorMaciej W. Rozycki <macro@linux-mips.org>2015-04-03 23:26:04 +0100
committerRalf Baechle <ralf@linux-mips.org>2015-04-08 01:09:49 +0200
commit18a2c2c6b9319503eeac8a38b62fc82c9ff81b0d (patch)
tree42c8af04bc532a7b77b07fea94a3ce647346a067 /arch/mips/include/asm/cpu-features.h
parentMIPS: math-emu: Make NaN classifiers static (diff)
downloadlinux-dev-18a2c2c6b9319503eeac8a38b62fc82c9ff81b0d.tar.xz
linux-dev-18a2c2c6b9319503eeac8a38b62fc82c9ff81b0d.zip
MIPS: Correct `nofpu' non-functionality
The `cpu_has_fpu' feature flag must not be hardcoded to 1 or the `nofpu' kernel option will be ignored. Remove any such overrides and add a cautionary note. Hardcoding to 0 is fine for FPU-less platforms. Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org> Cc: linux-mips@linux-mips.org Patchwork: https://patchwork.linux-mips.org/patch/9694/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/include/asm/cpu-features.h')
-rw-r--r--arch/mips/include/asm/cpu-features.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/mips/include/asm/cpu-features.h b/arch/mips/include/asm/cpu-features.h
index ea68a38bb61d..62a4730de86a 100644
--- a/arch/mips/include/asm/cpu-features.h
+++ b/arch/mips/include/asm/cpu-features.h
@@ -68,6 +68,7 @@
#ifndef cpu_has_octeon_cache
#define cpu_has_octeon_cache 0
#endif
+/* Don't override `cpu_has_fpu' to 1 or the "nofpu" option won't work. */
#ifndef cpu_has_fpu
#define cpu_has_fpu (current_cpu_data.options & MIPS_CPU_FPU)
#define raw_cpu_has_fpu (raw_current_cpu_data.options & MIPS_CPU_FPU)