diff options
author | Mike Larkin <mlarkin@cvs.openbsd.org> | 2016-09-03 11:38:09 +0000 |
---|---|---|
committer | Mike Larkin <mlarkin@cvs.openbsd.org> | 2016-09-03 11:38:09 +0000 |
commit | 69fabb0cbb0e09efadfd8d202a37f6ba6b8ba5d7 (patch) | |
tree | b68e59348bffb5bba06982360e4ad59b978aa780 /usr.sbin/vmd | |
parent | 35e448bc64248e025ec91066f13d27b71f283f61 (diff) |
As vmm(4) can now exit to vmd at any time to process pending interrupts,
don't kill the VM if we are presented with an exit type that is not
something we directly need to handle. Instead, simply re-enter the guest,
possibly injecting an interrupt along the way. Still exit the process
if presented with a triple fault, until we implement reboot support.
ok stefan@
Diffstat (limited to 'usr.sbin/vmd')
-rw-r--r-- | usr.sbin/vmd/vmm.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.sbin/vmd/vmm.c b/usr.sbin/vmd/vmm.c index f5383e1e8c4..e2cb8d4446d 100644 --- a/usr.sbin/vmd/vmm.c +++ b/usr.sbin/vmd/vmm.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vmm.c,v 1.43 2016/09/02 17:10:08 stefan Exp $ */ +/* $OpenBSD: vmm.c,v 1.44 2016/09/03 11:38:08 mlarkin Exp $ */ /* * Copyright (c) 2015 Mike Larkin <mlarkin@openbsd.org> @@ -1315,10 +1315,12 @@ vcpu_exit(struct vm_run_params *vrp) break; case VMX_EXIT_INT_WINDOW: break; + case VMX_EXIT_TRIPLE_FAULT: + log_warnx("%s: triple fault", __progname); + return (1); default: - log_warnx("%s: unknown exit reason %d", + log_debug("%s: unknown exit reason %d", __progname, vrp->vrp_exit_reason); - return (1); } /* XXX this may not be irq 9 all the time */ |