aboutsummaryrefslogtreecommitdiff
path: root/target-i386
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2011-01-21 21:48:06 +0100
committerMarcelo Tosatti <mtosatti@redhat.com>2011-01-23 02:27:20 -0200
commit73aaec4a39b3cf11082303a6cf6bcde8796c09c6 (patch)
tree9606fdae91367fe5aa6fb57b89a1a33539405049 /target-i386
parent646042e1aba31f377892e48f6145fbc8487d4481 (diff)
kvm: Stop on all fatal exit reasons
Ensure that we stop the guest whenever we face a fatal or unknown exit reason. If we stop, we also have to enforce a cpu loop exit. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'target-i386')
-rw-r--r--target-i386/kvm.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/target-i386/kvm.c b/target-i386/kvm.c
index 0aeb079004..6b4abaa6c0 100644
--- a/target-i386/kvm.c
+++ b/target-i386/kvm.c
@@ -1537,6 +1537,10 @@ int kvm_arch_handle_exit(CPUState *env, struct kvm_run *run)
case KVM_EXIT_SET_TPR:
ret = 1;
break;
+ default:
+ fprintf(stderr, "KVM: unknown exit reason %d\n", run->exit_reason);
+ ret = -1;
+ break;
}
return ret;