MIPS: XPA: Use XPA instructions in assembly
authorJames Hogan <jhogan@kernel.org>
Wed, 22 Nov 2017 11:30:30 +0000 (11:30 +0000)
committerJames Hogan <jhogan@kernel.org>
Mon, 22 Jan 2018 20:51:55 +0000 (20:51 +0000)
commit8e4789d288e0155db1929b5672252429e52b36a8
tree9854c6979a31354be2f95d58ac2edf00826ada55
parented21e00777c558dfd3ad2bc0a8f88bf4e204be75
MIPS: XPA: Use XPA instructions in assembly

Utilise XPA instructions MFHC0 & MTHC0 in inline assembly instead of
directly encoding them with the _ASM_INSN* macros, and transparently
implement these instructions as assembler macros if the toolchain
doesn't support them natively, using the recently introduced assembler
macro helpers.

The old direct encodings were restricted to using the register $at, so
this allows the extra register moves to go away (saving a grand total of
24 bytes).

Signed-off-by: James Hogan <jhogan@kernel.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/17775/
arch/mips/Makefile
arch/mips/include/asm/mipsregs.h