On encountering an unexpected VMEXIT (e.g. because L1 has used an
intercept that L0 Xen doesn't know about), crash the domain rather than
the hypervisor.
Fixes: 9a779e4fc161 ("Implement SVM specific part for Nested Virtualization")
Signed-off-by: Ross Lagerwall <ross.lagerwall@citrix.com>
---
This can be triggered running kvm-unit-tests in L1.
Xen undoubtedly needs to handle the intercepts properly but as a first
step it shouldn't BUG().
xen/arch/x86/hvm/svm/nestedsvm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/xen/arch/x86/hvm/svm/nestedsvm.c b/xen/arch/x86/hvm/svm/nestedsvm.c
index 3d0e77f5eb24..5adb1bd72c4d 100644
--- a/xen/arch/x86/hvm/svm/nestedsvm.c
+++ b/xen/arch/x86/hvm/svm/nestedsvm.c
@@ -923,7 +923,7 @@ nsvm_vmcb_guest_intercepts_exitcode(struct vcpu *v,
default:
gdprintk(XENLOG_ERR, "Illegal exitcode %#"PRIx64"\n", exitcode);
- BUG();
+ domain_crash(v->domain);
break;
}
--
2.53.0