diff mbox

problem with vm-exit exit code

Message ID bdf5bab31001181509r7dbecc7dp449f1ee85f3eae31@mail.gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Matteo Signorini Jan. 18, 2010, 11:09 p.m. UTC
None
diff mbox

Patch

--- x86/default_vmx.c 2010-01-18 11:24:11.726860478 +0100
+++ x86/vmx.c 2010-01-18 11:31:41.116842970 +0100
@@ -2347,6 +2347,7 @@ 
exec_control &= ~SECONDARY_EXEC_ENABLE_EPT;
if (!enable_unrestricted_guest)
exec_control &= ~SECONDARY_EXEC_UNRESTRICTED_
GUEST;
+ exec_control |= SECONDARY_EXEC_DT_EXITING;
vmcs_write32(SECONDARY_VM_EXEC_CONTROL, exec_control);
}

@@ -3398,6 +3399,10 @@ 
vmx->invalid_state_emulation_result = err;
}

+static void handle_gdtr_idtr_access(struct kvm_vcpu *vcpu, struct
kvm_run *kvm_run){
+ printk(KERN_INFO "line = %d\n",__LINE__);
+}
+
/*
* The exit handlers return 1 if the exit was handled fully and guest execution
* may resume. Otherwise they set the kvm_run parameter to indicate what needs
@@ -3435,6 +3440,7 @@ 
[EXIT_REASON_MCE_DURING_VMENTRY] =      handle_machine_check,
[EXIT_REASON_EPT_VIOLATION] =                    handle_ept_violation,
[EXIT_REASON_EPT_MISCONFIG] =                   handle_ept_misconfig,
+ [EXIT_REASON_ACCESS_GDTR_IDTR] =         handle_gdtr_idtr_access,
};


--- include/asm/default_vmx.h 2010-01-18 11:26:51.126860209 +0100
+++ include/asm/vmx.h 2010-01-18 11:33:23.866760764 +0100
@@ -96,6 +96,7 @@ 
#define SECONDARY_EXEC_ENABLE_VPID                0x00000020
#define SECONDARY_EXEC_WBINVD_EXITING            0x00000040
#define SECONDARY_EXEC_UNRESTRICTED_GUEST 0x00000080
+#define SECONDARY_EXEC_DT_EXITING                   0x00000004


@@ -291,6 +292,7 @@