diff options
Diffstat (limited to 'arch/x86/lguest')
-rw-r--r-- | arch/x86/lguest/boot.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/arch/x86/lguest/boot.c b/arch/x86/lguest/boot.c index ef4205c1a7a5..4e0c26559395 100644 --- a/arch/x86/lguest/boot.c +++ b/arch/x86/lguest/boot.c | |||
@@ -167,10 +167,16 @@ static void lazy_hcall3(unsigned long call, | |||
167 | 167 | ||
168 | /* When lazy mode is turned off reset the per-cpu lazy mode variable and then | 168 | /* When lazy mode is turned off reset the per-cpu lazy mode variable and then |
169 | * issue the do-nothing hypercall to flush any stored calls. */ | 169 | * issue the do-nothing hypercall to flush any stored calls. */ |
170 | static void lguest_leave_lazy_mode(void) | 170 | static void lguest_leave_lazy_mmu_mode(void) |
171 | { | 171 | { |
172 | paravirt_leave_lazy(paravirt_get_lazy_mode()); | ||
173 | kvm_hypercall0(LHCALL_FLUSH_ASYNC); | 172 | kvm_hypercall0(LHCALL_FLUSH_ASYNC); |
173 | paravirt_leave_lazy_mmu(); | ||
174 | } | ||
175 | |||
176 | static void lguest_end_context_switch(struct task_struct *next) | ||
177 | { | ||
178 | kvm_hypercall0(LHCALL_FLUSH_ASYNC); | ||
179 | paravirt_end_context_switch(next); | ||
174 | } | 180 | } |
175 | 181 | ||
176 | /*G:033 | 182 | /*G:033 |
@@ -1054,8 +1060,8 @@ __init void lguest_init(void) | |||
1054 | pv_cpu_ops.write_gdt_entry = lguest_write_gdt_entry; | 1060 | pv_cpu_ops.write_gdt_entry = lguest_write_gdt_entry; |
1055 | pv_cpu_ops.write_idt_entry = lguest_write_idt_entry; | 1061 | pv_cpu_ops.write_idt_entry = lguest_write_idt_entry; |
1056 | pv_cpu_ops.wbinvd = lguest_wbinvd; | 1062 | pv_cpu_ops.wbinvd = lguest_wbinvd; |
1057 | pv_cpu_ops.lazy_mode.enter = paravirt_enter_lazy_cpu; | 1063 | pv_cpu_ops.start_context_switch = paravirt_start_context_switch; |
1058 | pv_cpu_ops.lazy_mode.leave = lguest_leave_lazy_mode; | 1064 | pv_cpu_ops.end_context_switch = lguest_end_context_switch; |
1059 | 1065 | ||
1060 | /* pagetable management */ | 1066 | /* pagetable management */ |
1061 | pv_mmu_ops.write_cr3 = lguest_write_cr3; | 1067 | pv_mmu_ops.write_cr3 = lguest_write_cr3; |
@@ -1068,7 +1074,7 @@ __init void lguest_init(void) | |||
1068 | pv_mmu_ops.read_cr2 = lguest_read_cr2; | 1074 | pv_mmu_ops.read_cr2 = lguest_read_cr2; |
1069 | pv_mmu_ops.read_cr3 = lguest_read_cr3; | 1075 | pv_mmu_ops.read_cr3 = lguest_read_cr3; |
1070 | pv_mmu_ops.lazy_mode.enter = paravirt_enter_lazy_mmu; | 1076 | pv_mmu_ops.lazy_mode.enter = paravirt_enter_lazy_mmu; |
1071 | pv_mmu_ops.lazy_mode.leave = lguest_leave_lazy_mode; | 1077 | pv_mmu_ops.lazy_mode.leave = lguest_leave_lazy_mmu_mode; |
1072 | pv_mmu_ops.pte_update = lguest_pte_update; | 1078 | pv_mmu_ops.pte_update = lguest_pte_update; |
1073 | pv_mmu_ops.pte_update_defer = lguest_pte_update; | 1079 | pv_mmu_ops.pte_update_defer = lguest_pte_update; |
1074 | 1080 | ||