]> git.baikalelectronics.ru Git - kernel.git/commit
s390/nospec: generate single register thunks if possible
authorVasily Gorbik <gor@linux.ibm.com>
Mon, 28 Feb 2022 12:15:59 +0000 (13:15 +0100)
committerVasily Gorbik <gor@linux.ibm.com>
Thu, 10 Mar 2022 14:58:17 +0000 (15:58 +0100)
commite7cf0840332fa73f025a291106e8ffb8bb8dc32b
tree04e860d466ae873384a96f28ee51fbc341fa4d2c
parenta92ca7ff568a83c04ad8199d7cd03265a02d6164
s390/nospec: generate single register thunks if possible

Currently assembler generated expoline thunks are always in a form
__s390_indirect_jump_rXuse_rX even when exrl instruction is available
and no additional register is utilized.

Generate __s390_indirect_jump_rX versions using a single register if the
kernel is built for z10 or newer machine, which have exrl instruction
available. Thunks generated are identical to the ones generated by the
compiler.

This helps to reduce the number of thunks for newer machines generations.

Acked-by: Sumanth Korikkar <sumanthk@linux.ibm.com>
Acked-by: Ilya Leoshkevich <iii@linux.ibm.com>
Signed-off-by: Vasily Gorbik <gor@linux.ibm.com>
arch/s390/include/asm/nospec-insn.h