* [PATCH] KVM: Fix EPT with WP bit change during paging
@ 2009-08-19 1:52 Sheng Yang
2009-08-19 8:16 ` Avi Kivity
0 siblings, 1 reply; 2+ messages in thread
From: Sheng Yang @ 2009-08-19 1:52 UTC (permalink / raw)
To: Avi Kivity; +Cc: kvm, Sheng Yang
QNX update WP bit when paging enabled, which is not covered yet. This one fix
QNX boot with EPT.
Signed-off-by: Sheng Yang <sheng@linux.intel.com>
---
I think it's also necessary for 2.6.31?
arch/x86/kvm/vmx.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 2b7e7bd..1ee811c 100644
--- a/arch/x86/kvm/vmx.c
+++ b/arch/x86/kvm/vmx.c
@@ -1642,7 +1642,6 @@ static void ept_update_paging_mode_cr0(unsigned long *hw_cr0,
CPU_BASED_CR3_STORE_EXITING));
vcpu->arch.cr0 = cr0;
vmx_set_cr4(vcpu, vcpu->arch.cr4);
- *hw_cr0 &= ~X86_CR0_WP;
} else if (!is_paging(vcpu)) {
/* From nonpaging to paging */
vmcs_write32(CPU_BASED_VM_EXEC_CONTROL,
@@ -1651,9 +1650,10 @@ static void ept_update_paging_mode_cr0(unsigned long *hw_cr0,
CPU_BASED_CR3_STORE_EXITING));
vcpu->arch.cr0 = cr0;
vmx_set_cr4(vcpu, vcpu->arch.cr4);
- if (!(vcpu->arch.cr0 & X86_CR0_WP))
- *hw_cr0 &= ~X86_CR0_WP;
}
+
+ if (!(cr0 & X86_CR0_WP))
+ *hw_cr0 &= ~X86_CR0_WP;
}
static void ept_update_paging_mode_cr4(unsigned long *hw_cr4,
--
1.5.4.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] KVM: Fix EPT with WP bit change during paging
2009-08-19 1:52 [PATCH] KVM: Fix EPT with WP bit change during paging Sheng Yang
@ 2009-08-19 8:16 ` Avi Kivity
0 siblings, 0 replies; 2+ messages in thread
From: Avi Kivity @ 2009-08-19 8:16 UTC (permalink / raw)
To: Sheng Yang; +Cc: kvm
On 08/19/2009 04:52 AM, Sheng Yang wrote:
> QNX update WP bit when paging enabled, which is not covered yet. This one fix
> QNX boot with EPT.
>
Applied, thanks.
> I think it's also necessary for 2.6.31?
>
It's not a recent regression, right? So I'll send it for 2.6.32 and
afterwards to 2.6.31.stable.
--
error compiling committee.c: too many arguments to function
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-08-19 8:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-19 1:52 [PATCH] KVM: Fix EPT with WP bit change during paging Sheng Yang
2009-08-19 8:16 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).