Skip to contentSkip to conversation

Walk and print EPT tables on an unexpected EPT violation

PATCH New George Dunlap 1 participant 1 message Jan 7, 2010

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Walk and print EPT tables on an unexpected EPT violation

Wrote this when I was tracking down the HAP-PoD problem, figured it might come in handy sometime.

xen/arch/x86/hvm/vmx/vmx.c +2 -0
diff -r cba56c13ca3e xen/arch/x86/hvm/vmx/vmx.c
@@ -2116,6 +2116,8 @@
              (qualification & EPT_EFFECTIVE_EXEC) ? 'x' : '-',
              gpa, mfn_x(mfn), p2mt);
 
+    ept_walk_table(current->domain, gfn);
+
     if ( qualification & EPT_GLA_VALID )
     {
         gla = __vmread(GUEST_LINEAR_ADDRESS);
xen/arch/x86/mm/hap/p2m-ept.c +49 -0

55 lines not on this page · raw message

xen/include/asm-x86/hvm/vmx/vmx.h +1 -0
diff -r cba56c13ca3e xen/include/asm-x86/hvm/vmx/vmx.h
@@ -357,6 +357,7 @@
 void vmx_inject_nmi(void);
 
 void ept_p2m_init(struct domain *d);
+void ept_walk_table(struct domain *d, unsigned long gfn);
 
 /* EPT violation qualifications definitions */
 #define _EPT_READ_VIOLATION         0

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xensource.com/xen-devel