jump_label, x86: Add variable length patching support
authorPeter Zijlstra <peterz@infradead.org>
Thu, 6 May 2021 19:33:59 +0000 (21:33 +0200)
committerIngo Molnar <mingo@kernel.org>
Wed, 12 May 2021 12:54:55 +0000 (14:54 +0200)
commit001951bea748d3f675e1778f42b17290a8c551bf
tree12e445db34ea8f21e899512340d6ab958bc5e3bd
parentfa5e5dc39669b4427830c546ede8709323b8276c
jump_label, x86: Add variable length patching support

This allows the patching to to emit 2 byte JMP/NOP instruction in
addition to the 5 byte JMP/NOP we already did. This allows for more
compact code.

This code is not yet used, as we don't emit shorter code at compile
time yet.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20210506194157.846870383@infradead.org
arch/x86/kernel/jump_label.c