summaryrefslogtreecommitdiffstats
path: root/sys/amd64/vmm
diff options
context:
space:
mode:
authorneel <neel@FreeBSD.org>2014-10-16 18:16:31 +0000
committerneel <neel@FreeBSD.org>2014-10-16 18:16:31 +0000
commit8bc5fc92e5a7edcf0291ae4396b8f4360bb42171 (patch)
tree802952522e96f89f9863dcaa8db53c0cd5337004 /sys/amd64/vmm
parent09fbd3f7d9734eda1582ea172e88cda9b67285bc (diff)
downloadFreeBSD-src-8bc5fc92e5a7edcf0291ae4396b8f4360bb42171.zip
FreeBSD-src-8bc5fc92e5a7edcf0291ae4396b8f4360bb42171.tar.gz
Use the correct fault type (VM_PROT_EXECUTE) for an instruction fetch.
Diffstat (limited to 'sys/amd64/vmm')
-rw-r--r--sys/amd64/vmm/amd/svm.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/amd64/vmm/amd/svm.c b/sys/amd64/vmm/amd/svm.c
index 0af4da3..e59f723 100644
--- a/sys/amd64/vmm/amd/svm.c
+++ b/sys/amd64/vmm/amd/svm.c
@@ -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);
}
OpenPOWER on IntegriCloud