[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 06/24] kvm: Add kvm system event crash handler
From: |
Paolo Bonzini |
Subject: |
[Qemu-devel] [PULL 06/24] kvm: Add kvm system event crash handler |
Date: |
Wed, 16 Sep 2015 14:29:37 +0200 |
From: Andrey Smetanin <address@hidden>
KVM kernel can send guest crash events into userspace.
Appropriate guest crash handler is called when kernel guest
crash event received. Guest crash event recognized by a
KVM_SYSTEM_EVENT_CRASH type of system event.
Signed-off-by: Andrey Smetanin <address@hidden>
Signed-off-by: Denis V. Lunev <address@hidden>
CC: Paolo Bonzini <address@hidden>
CC: Andreas Färber <address@hidden>
Message-Id: <address@hidden>
[Rebase: add lock/unlock iothread around qemu_system_guest_panicked - Paolo]
Signed-off-by: Paolo Bonzini <address@hidden>
---
kvm-all.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/kvm-all.c b/kvm-all.c
index c6f5128..de1924c 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -1889,6 +1889,12 @@ int kvm_cpu_exec(CPUState *cpu)
qemu_system_reset_request();
ret = EXCP_INTERRUPT;
break;
+ case KVM_SYSTEM_EVENT_CRASH:
+ qemu_mutex_lock_iothread();
+ qemu_system_guest_panicked();
+ qemu_mutex_unlock_iothread();
+ ret = 0;
+ break;
default:
DPRINTF("kvm_arch_handle_exit\n");
ret = kvm_arch_handle_exit(cpu, run);
--
2.5.0
- [Qemu-devel] [PULL 00/24] Misc patches for 2015-09-16, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 01/24] pci: remove Link Training error from AER error list, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 02/24] update Linux headers to 4.3-rc1, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 06/24] kvm: Add kvm system event crash handler,
Paolo Bonzini <=
- [Qemu-devel] [PULL 03/24] update-linux-headers: copy standard-headers files one by one, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 04/24] target-i386: move asm-x86/hyperv.h to standard-headers, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 05/24] cpu: Add crash_occurred flag into CPUState, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 08/24] hmp-commands-info: move info_cmds content out of monitor.c, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 07/24] i386/kvm: Hyper-v crash msrs set/get'ers and migration, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 10/24] hmp-commands.hx: fix end of table info, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 12/24] qemu-char: Use g_new() & friends where that makes obvious sense, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 11/24] monitor: added generation of documentation for hmp-commands-info.hx, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 13/24] cpu-exec: Migrate some generic fns to cpu-exec-common, Paolo Bonzini, 2015/09/16
- [Qemu-devel] [PULL 14/24] translate-all: Move tcg_handle_interrupt() to -common, Paolo Bonzini, 2015/09/16