]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - arch/x86/kernel/kvm.c
KVM: Let host know whether the guest can handle async PF in non-userspace context.
[mv-sheeva.git] / arch / x86 / kernel / kvm.c
index 47ea93e6b0d816a8b53860825c1a409a06e6a200..91b3d650898c70beef6f9d3ff365b924254ce501 100644 (file)
@@ -449,6 +449,9 @@ void __cpuinit kvm_guest_cpu_init(void)
        if (kvm_para_has_feature(KVM_FEATURE_ASYNC_PF) && kvmapf) {
                u64 pa = __pa(&__get_cpu_var(apf_reason));
 
+#ifdef CONFIG_PREEMPT
+               pa |= KVM_ASYNC_PF_SEND_ALWAYS;
+#endif
                wrmsrl(MSR_KVM_ASYNC_PF_EN, pa | KVM_ASYNC_PF_ENABLED);
                __get_cpu_var(apf_reason).enabled = 1;
                printk(KERN_INFO"KVM setup async PF for cpu %d\n",