Commit 634e781b authored by Ravikiran Thirumalai's avatar Ravikiran Thirumalai Committed by Greg Kroah-Hartman

x86: Fix 27-rc crash on vsmp due to paravirt during module load

commit 05e12e1c upstream.

vsmp_patch has been marked with __init ever since pvops, however,
apply_paravirt can be called during module load causing calls to
freed memory location.

Since apply_paravirt can only be called during bootup and module load,
mark vsmp patch with "__init_or_module"
Signed-off-by: default avatarRavikiran Thirumalai <kiran@scalex86.org>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent e568b360
...@@ -58,7 +58,7 @@ static void vsmp_irq_enable(void) ...@@ -58,7 +58,7 @@ static void vsmp_irq_enable(void)
native_restore_fl((flags | X86_EFLAGS_IF) & (~X86_EFLAGS_AC)); native_restore_fl((flags | X86_EFLAGS_IF) & (~X86_EFLAGS_AC));
} }
static unsigned __init vsmp_patch(u8 type, u16 clobbers, void *ibuf, static unsigned __init_or_module vsmp_patch(u8 type, u16 clobbers, void *ibuf,
unsigned long addr, unsigned len) unsigned long addr, unsigned len)
{ {
switch (type) { switch (type) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment