linux/arch/mips/kernel
Paul Burton 597ce1723e MIPS: Support for 64-bit FP with O32 binaries
CPUs implementing MIPS32 R2 may include a 64-bit FPU, just as MIPS64 CPUs
do. In order to preserve backwards compatibility a 64-bit FPU will act
like a 32-bit FPU (by accessing doubles from the least significant 32
bits of an even-odd pair of FP registers) when the Status.FR bit is
zero, again just like a mips64 CPU. The standard O32 ABI is defined
expecting a 32-bit FPU, however recent toolchains support use of a
64-bit FPU from an O32 MIPS32 executable. When an ELF executable is
built to use a 64-bit FPU a new flag (EF_MIPS_FP64) is set in the ELF
header.

With this patch the kernel will check the EF_MIPS_FP64 flag when
executing an O32 binary, and set Status.FR accordingly. The addition
of O32 64-bit FP support lessens the opportunity for optimisation in
the FPU emulator, so a CONFIG_MIPS_O32_FP64_SUPPORT Kconfig option is
introduced to allow this support to be disabled for those that don't
require it.

Inspired by an earlier patch by Leonid Yegoshin, but implemented more
cleanly & correctly.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Cc: Paul Burton <paul.burton@imgtec.com>
Patchwork: https://patchwork.linux-mips.org/patch/6154/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2014-01-13 23:40:56 +01:00
..
.gitignore
8250-platform.c mips: remove needless include of module.h from core kernel files. 2011-10-31 19:30:57 -04:00
asm-offsets.c MIPS: r4k,octeon,r2300: stack protector: change canary per task 2013-07-01 15:10:52 +02:00
binfmt_elfn32.c MIPS: Compat: Fix cputime_to_timeval() arguments in compat binfmt_elf. 2013-06-06 16:11:26 +02:00
binfmt_elfo32.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
bmips_vec.S MIPS: BMIPS: fix slave CPU booting when physical CPU is not 0 2013-07-30 18:54:29 +02:00
branch.c MIPS: Cleanup indentation and whitespace 2013-07-01 15:10:57 +02:00
cevt-bcm1480.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cevt-ds1287.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
cevt-gic.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cevt-gt641xx.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
cevt-r4k.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cevt-sb1250.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cevt-smtc.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cevt-txx9.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
cpu-bugs64.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
cpu-probe.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
crash_dump.c mips: remove savemaxmem parameter setup 2013-07-03 16:08:03 -07:00
crash.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
csrc-bcm1480.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
csrc-gic.c MIPS: Refactor GIC clocksource code. 2013-05-09 17:55:20 +02:00
csrc-ioasic.c MIPS: DECstation HRT initialization rearrangement 2013-09-13 11:56:13 +02:00
csrc-r4k.c
csrc-sb1250.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
early_printk_8250.c MIPS: Add 8250/16550 serial early printk driver 2013-10-29 21:24:36 +01:00
early_printk.c early_printk: consolidate random copies of identical code 2013-04-29 18:28:13 -07:00
entry.S Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/signal 2012-12-12 12:22:13 -08:00
ftrace.c MIPS: O32 / 32-bit: Always copy 4 stack arguments. 2013-10-29 21:25:02 +01:00
genex.S MIPS: Print correct PC in trace dump after NMI exception 2013-10-29 21:25:35 +01:00
gpio_txx9.c
head.S MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
i8253.c MIPS: irq: Remove IRQF_DISABLED 2011-12-07 22:03:45 +00:00
i8259.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
idle.c MIPS: Optimize current_cpu_type() for better code. 2013-09-17 18:50:53 +02:00
irq_cpu.c MIPS: Panic messages should not end in \n. 2013-10-29 21:24:19 +01:00
irq_txx9.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
irq-gic.c MIPS: GIC: Fix gic_set_affinity infinite loop 2013-07-01 15:10:56 +02:00
irq-gt641xx.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
irq-msc01.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
irq-rm7000.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
irq.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
jump_label.c
kgdb.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
kprobes.c kprobes/mips: Fix to check double free of insn slot 2013-05-22 12:48:30 +02:00
linux32.c unify compat fanotify_mark(2), switch to COMPAT_SYSCALL_DEFINE 2013-05-09 13:46:38 -04:00
machine_kexec.c MIPS: kdump: Add support 2012-12-13 16:46:47 +01:00
Makefile MIPS: PowerTV: Remove support code. 2013-10-29 21:25:17 +01:00
mcount.S MIPS: Ftrace: Fix function tracing return address to match 2013-09-03 14:46:27 +02:00
mips_ksyms.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
mips_machine.c MIPS: move mips_{set,get}_machine_name() to a more generic place 2013-05-08 01:19:07 +02:00
mips-mt-fpaff.c sched: Rename sched.c as sched/core.c in comments and Documentation 2013-06-19 12:58:42 +02:00
mips-mt.c Merge branch 'master' into for-next 2012-04-08 21:48:52 +02:00
module-rela.c MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
module.c MIPS: Use NUMA_NO_NODE instead of -1 for node ID. 2013-10-29 21:24:14 +01:00
octeon_switch.S MIPS: stack protector: Fix per-task canary switch 2013-10-07 15:31:04 +02:00
perf_event_mipsxx.c MIPS: Perf: Fix 74K cache map 2013-10-29 21:18:23 +01:00
perf_event.c MIPS: perf: Reorganize contents of perf support files. 2011-10-24 23:34:26 +01:00
proc.c MIPS: Get rid of MIPS I flag and test macros. 2013-07-01 15:10:56 +02:00
process.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
prom.c mips: use common of_flat_dt_get_machine_name 2013-10-09 20:03:57 -05:00
ptrace32.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
ptrace.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
r4k_fpu.S MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
r4k_switch.S MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
r2300_fpu.S MIPS: Whitespace cleanup. 2013-02-01 10:00:22 +01:00
r2300_switch.S MIPS: stack protector: Fix per-task canary switch 2013-10-07 15:31:04 +02:00
r6000_fpu.S
relocate_kernel.S MIPS: kdump: Skip walking indirection page for crashkernels 2013-09-05 20:53:37 +02:00
reset.c mips: migrate core kernel file from module.h --> export.h 2011-10-31 19:30:56 -04:00
rtlx.c sched/wait: Make the __wait_event*() interface more friendly 2013-10-04 10:16:25 +02:00
scall32-o32.S MIPS: O32 / 32-bit: Always copy 4 stack arguments. 2013-10-29 21:25:02 +01:00
scall64-64.S MIPS: 64-bit: Mark native syscall table as data object. 2013-10-29 21:24:55 +01:00
scall64-n32.S MIPS: compat: Mark N32 syscall table as data object. 2013-10-29 21:24:54 +01:00
scall64-o32.S MIPS: compat: Export O32 syscall table and rename to avoid duplicate symbol. 2013-10-29 21:24:52 +01:00
setup.c MIPS: Fix start of free memory when using initrd 2013-10-29 21:24:23 +01:00
signal32.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
signal_n32.c Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2013-03-02 07:44:16 -08:00
signal-common.h most of set_current_blocked() callers want SIGKILL/SIGSTOP removed from set 2012-06-01 12:58:51 -04:00
signal.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
smp-bmips.c MIPS: Panic messages should not end in \n. 2013-10-29 21:24:19 +01:00
smp-cmp.c MIPS: Fix SMP core calculations when using MT support. 2013-09-13 11:59:51 +02:00
smp-mt.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
smp-up.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
smp.c MIPS: SMP: kill redundant call of generic_smp_call_function_single_interrupt() 2013-10-29 21:23:45 +01:00
smtc-asm.S MIPS: microMIPS: Add support for exception handling. 2013-05-09 17:55:18 +02:00
smtc-proc.c mips: single_open() leaks 2013-05-05 00:10:21 -04:00
smtc.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
spinlock_test.c mips: migrate core kernel file from module.h --> export.h 2011-10-31 19:30:56 -04:00
spram.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
stacktrace.c mips: migrate core kernel file from module.h --> export.h 2011-10-31 19:30:56 -04:00
sync-r4k.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00
syscall.c Merge branch 'upstream' of git://git.linux-mips.org/pub/scm/ralf/upstream-linus 2013-03-02 07:44:16 -08:00
time.c MIPS: Optimize current_cpu_type() for better code. 2013-09-17 18:50:53 +02:00
topology.c
traps.c MIPS: Support for 64-bit FP with O32 binaries 2014-01-13 23:40:56 +01:00
unaligned.c MIPS: Declare emulate_load_store_microMIPS as a static function. 2013-07-01 15:10:57 +02:00
vdso.c coredump: remove VM_ALWAYSDUMP flag 2012-03-23 16:58:42 -07:00
vmlinux.lds.S MIPS: Discard .eh_frame sections in linker script. 2013-08-26 15:33:41 +02:00
vpe.c MIPS: kernel: vpe: Make vpe_attrs an array of pointers. 2013-09-13 15:12:48 +02:00
watch.c MIPS: Delete __cpuinit/__CPUINIT usage from MIPS code 2013-07-14 19:36:51 -04:00