[patch 0/3] x86/paravirt: Rework paravirt patching

From: Thomas Gleixner
Date: Wed Apr 24 2019 - 09:47:37 EST


Andi tried to make the paravirt patch magic work nicely with LTO. It turned
out that the DEF_NATIVE() macro is clever but fragile. Even without LTO it
works by chance and not by design.

As the paravirt patch tables are not changed frequently it's reasonable to
convert them to regular data which is initialized with byte sequences.

Looking at Andi's attempt to change the existing code made me realize
that there is no real reason to have two variants for 32 and 64 bit
which just differ slightly.

The following series unifies the 32/64bit implementation and converts
it to use regular data at the end.

Thanks,

tglx

8<--------------
a/arch/x86/kernel/paravirt_patch_32.c | 67 ------------------
a/arch/x86/kernel/paravirt_patch_64.c | 75 --------------------
arch/x86/include/asm/paravirt_types.h | 4 -
arch/x86/kernel/Makefile | 4 -
b/arch/x86/kernel/paravirt_patch.c | 126 ++++++++++++++++++++++++++++++++++
5 files changed, 128 insertions(+), 148 deletions(-)