svn commit: r273176 - projects/bhyve_svm/sys/amd64/vmm/amd

Neel Natu neel at FreeBSD.org
Thu Oct 16 18:16:32 UTC 2014


Author: neel
Date: Thu Oct 16 18:16:31 2014
New Revision: 273176
URL: https://svnweb.freebsd.org/changeset/base/273176

Log:
  Use the correct fault type (VM_PROT_EXECUTE) for an instruction fetch.

Modified:
  projects/bhyve_svm/sys/amd64/vmm/amd/svm.c

Modified: projects/bhyve_svm/sys/amd64/vmm/amd/svm.c
==============================================================================
--- projects/bhyve_svm/sys/amd64/vmm/amd/svm.c	Thu Oct 16 18:13:10 2014	(r273175)
+++ projects/bhyve_svm/sys/amd64/vmm/amd/svm.c	Thu Oct 16 18:16:31 2014	(r273176)
@@ -752,6 +752,8 @@ npf_fault_type(uint64_t exitinfo1)
 
 	if (exitinfo1 & VMCB_NPF_INFO1_W)
 		return (VM_PROT_WRITE);
+	else if (exitinfo1 & VMCB_NPF_INFO1_ID)
+		return (VM_PROT_EXECUTE);
 	else
 		return (VM_PROT_READ);
 }


More information about the svn-src-projects mailing list