c5eca2
diff -up ./arch/x86/kernel/cpu/common.c.dist ./arch/x86/kernel/cpu/common.c
c5eca2
--- ./arch/x86/kernel/cpu/common.c.dist	2017-12-29 03:59:43.000000000 +0900
c5eca2
+++ ./arch/x86/kernel/cpu/common.c	2018-01-10 15:37:06.848478838 +0900
c5eca2
@@ -1349,6 +1349,9 @@ DEFINE_PER_CPU(struct task_struct *, fpu
c5eca2
 DEFINE_PER_CPU_ALIGNED(struct stack_canary, stack_canary);
c5eca2
 #endif
c5eca2
 
c5eca2
+DEFINE_PER_CPU_USER_MAPPED(struct kernel_ibrs_spec_ctrl, spec_ctrl_pcp);
c5eca2
+EXPORT_PER_CPU_SYMBOL_GPL(spec_ctrl_pcp);
c5eca2
+
c5eca2
 #endif	/* CONFIG_X86_64 */
c5eca2
 
c5eca2
 /*
c5eca2
diff -up ./arch/x86/include/asm/spec_ctrl.h.dist ./arch/x86/include/asm/spec_ctrl.h
c5eca2
--- ./arch/x86/include/asm/spec_ctrl.h.dist    2018-06-15 13:57:32.000000000 -0700
c5eca2
+++ ./arch/x86/include/asm/spec_ctrl.h 2019-05-14 17:48:21.451670849 -0700
c5eca2
@@ -191,6 +191,8 @@ extern void spec_ctrl_cpu_init(void);
c5eca2
 extern void ssb_print_mitigation(void);
c5eca2
 extern void mds_print_mitigation(void);
c5eca2
 
c5eca2
+DECLARE_PER_CPU_USER_MAPPED(struct kernel_ibrs_spec_ctrl, spec_ctrl_pcp);
c5eca2
+
c5eca2
 bool spec_ctrl_force_enable_ibrs(void);
c5eca2
 bool spec_ctrl_cond_enable_ibrs(bool full_retpoline);
c5eca2
 bool spec_ctrl_enable_ibrs_always(void);
c5eca2
diff -up ./arch/x86/kernel/reboot.c.dist ./arch/x86/kernel/reboot.c
c5eca2
--- ./arch/x86/kernel/reboot.c.dist	2017-12-29 03:59:43.000000000 +0900
c5eca2
+++ ./arch/x86/kernel/reboot.c	2018-01-10 15:43:36.819240224 +0900
c5eca2
@@ -23,6 +23,7 @@
c5eca2
 #include <asm/cpu.h>
c5eca2
 #include <asm/nmi.h>
c5eca2
 #include <asm/smp.h>
c5eca2
+#include <asm/mmu_context.h>
c5eca2
 
c5eca2
 #include <linux/ctype.h>
c5eca2
 #include <linux/mc146818rtc.h>
c5eca2
diff -up ./arch/x86/kernel/smpboot.c.dist ./arch/x86/kernel/smpboot.c
c5eca2
--- ./arch/x86/kernel/smpboot.c.dist	2018-01-10 14:53:15.251175037 +0900
c5eca2
+++ ./arch/x86/kernel/smpboot.c	2018-01-10 15:45:14.219976320 +0900
c5eca2
@@ -72,6 +72,7 @@
c5eca2
 #include <asm/fpu-internal.h>
c5eca2
 #include <asm/setup.h>
c5eca2
 #include <asm/uv/uv.h>
c5eca2
+#include <asm/mmu_context.h>
c5eca2
 #include <linux/mc146818rtc.h>
c5eca2
 
c5eca2
 #include <asm/smpboot_hooks.h>
c5eca2
diff -up ./arch/x86/platform/efi/efi_32.c.dist ./arch/x86/platform/efi/efi_32.c
c5eca2
--- ./arch/x86/platform/efi/efi_32.c.dist	2017-12-29 03:59:43.000000000 +0900
c5eca2
+++ ./arch/x86/platform/efi/efi_32.c	2018-01-10 15:45:56.356433372 +0900
c5eca2
@@ -30,6 +30,7 @@
c5eca2
 #include <asm/pgtable.h>
c5eca2
 #include <asm/tlbflush.h>
c5eca2
 #include <asm/efi.h>
c5eca2
+#include <asm/mmu_context.h>
c5eca2
 
c5eca2
 /*
c5eca2
  * To make EFI call EFI runtime service in physical addressing mode we need
c5eca2