]> git.proxmox.com Git - mirror_qemu.git/commitdiff
vl: log available guest crash information
authorAnton Nefedov <anton.nefedov@virtuozzo.com>
Tue, 14 Feb 2017 06:25:24 +0000 (09:25 +0300)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 16 Feb 2017 14:30:49 +0000 (15:30 +0100)
There is a suitable log mask for the purpose.

Signed-off-by: Anton Nefedov <anton.nefedov@virtuozzo.com>
Signed-off-by: Denis V. Lunev <den@openvz.org>
Message-Id: <1487053524-18674-4-git-send-email-den@openvz.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
vl.c

diff --git a/vl.c b/vl.c
index 599327018500c4869122499d2efe3b31d72f742b..27d982981ab5e667d96c69b2f2e4b06a19c7daaf 100644 (file)
--- a/vl.c
+++ b/vl.c
@@ -1681,6 +1681,8 @@ void qemu_system_reset(bool report)
 
 void qemu_system_guest_panicked(GuestPanicInformation *info)
 {
+    qemu_log_mask(LOG_GUEST_ERROR, "Guest crashed\n");
+
     if (current_cpu) {
         current_cpu->crash_occurred = true;
     }
@@ -1694,6 +1696,15 @@ void qemu_system_guest_panicked(GuestPanicInformation *info)
     }
 
     if (info) {
+        if (info->type == GUEST_PANIC_INFORMATION_KIND_HYPER_V) {
+            qemu_log_mask(LOG_GUEST_ERROR, "HV crash parameters: (%#"PRIx64
+                          " %#"PRIx64" %#"PRIx64" %#"PRIx64" %#"PRIx64")\n",
+                          info->u.hyper_v.data->arg1,
+                          info->u.hyper_v.data->arg2,
+                          info->u.hyper_v.data->arg3,
+                          info->u.hyper_v.data->arg4,
+                          info->u.hyper_v.data->arg5);
+        }
         qapi_free_GuestPanicInformation(info);
     }
 }