x86/paravirt: Switch functions with custom code to ALTERNATIVE
authorJuergen Gross <jgross@suse.com>
Thu, 11 Mar 2021 14:23:18 +0000 (15:23 +0100)
committerBorislav Petkov <bp@suse.de>
Thu, 11 Mar 2021 19:07:01 +0000 (20:07 +0100)
commitfafe5e74229fd3f425e3cbfc68b90e615aa6d62f
tree4d90e0af0c7a2611cbeb3f7fcc5560c4bd6eeee9
parent00aa3193ab7a04b25bb8c68e377815696eb5bf56
x86/paravirt: Switch functions with custom code to ALTERNATIVE

Instead of using paravirt patching for custom code sequences use
ALTERNATIVE for the functions with custom code replacements.

Instead of patching an ud2 instruction for unpopulated vector entries
into the caller site, use a simple function just calling BUG() as a
replacement.

Simplify the register defines for assembler paravirt calling, as there
isn't much usage left.

Signed-off-by: Juergen Gross <jgross@suse.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20210311142319.4723-14-jgross@suse.com
arch/x86/entry/entry_64.S
arch/x86/include/asm/irqflags.h
arch/x86/include/asm/paravirt.h
arch/x86/include/asm/paravirt_types.h
arch/x86/kernel/paravirt.c
arch/x86/kernel/paravirt_patch.c