# HG changeset patch # User Travis Betak # Date 1173133090 21600 # Node ID e464aa6237ef87f4df78e3cb27fdc6d5b04a0109 # Parent ed9482ef7a35811359798e4ca4d532a9ee36b87a [SVM] Return the shadow EFER value on guest EFER reads. Return the shadow of the guest's EFER instead of the VMCB. This helps with things such as the unlikely event the guest wants to check EFER.LME immediately after setting it (The VMCB's EFER.LME remains clear until the guest enables paging). Signed-off-by: Travis Betak diff -r ed9482ef7a35 -r e464aa6237ef xen/arch/x86/hvm/svm/svm.c --- a/xen/arch/x86/hvm/svm/svm.c Mon Mar 05 16:17:25 2007 -0600 +++ b/xen/arch/x86/hvm/svm/svm.c Mon Mar 05 16:18:10 2007 -0600 @@ -187,8 +187,7 @@ static inline int long_mode_do_msr_read( switch ((u32)regs->ecx) { case MSR_EFER: - msr_content = vmcb->efer; - msr_content &= ~EFER_SVME; + msr_content = v->arch.hvm_svm.cpu_shadow_efer; break; #ifdef __x86_64__