]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: Clear upper bits of FP registers on emulator writes
authorPaul Burton <paul.burton@imgtec.com>
Mon, 27 Jan 2014 17:14:47 +0000 (17:14 +0000)
committerRalf Baechle <ralf@linux-mips.org>
Wed, 26 Mar 2014 22:09:10 +0000 (23:09 +0100)
commitd7c5e41387dc81c7b1011e4c3cf2ad8b92a9dabf
tree4a7912f9c445ceb5a6fec92e3257048e507c56c2
parent4765f98e20a9e4a34030b540ad04d8f2d2f5c7bf
MIPS: Clear upper bits of FP registers on emulator writes

The upper bits of an FP register are architecturally defined as
unpredictable following an instructions which only writes the lower
bits. The prior behaviour of the kernel is to leave them unmodified.
This patch modifies that to clear the upper bits to zero. This is what
the MSA architecture reference manual specifies should happen for its
wider registers and is still permissible for scalar FP instructions
given the bits unpredictability there.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Cc: linux-mips@linux-mips.org
Cc: sergei.shtylyov@cogentembedded.com
Patchwork: https://patchwork.linux-mips.org/patch/6435/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/math-emu/cp1emu.c