mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
pvpanic: implement crashloaded event handling
Handle bit 1 write, then post event to monitor. Suggested by Paolo, declear a new event, using GUEST_PANICKED could cause upper layers to react by shutting down or rebooting the guest. In advance for extention, add GuestPanicInformation in event message. Signed-off-by: zhenwei pi <pizhenwei@bytedance.com> Message-Id: <20200114023102.612548-3-pizhenwei@bytedance.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
600d7b47e8
commit
7dc58deea7
5 changed files with 52 additions and 12 deletions
12
vl.c
12
vl.c
|
@ -1468,6 +1468,18 @@ void qemu_system_guest_panicked(GuestPanicInformation *info)
|
|||
}
|
||||
}
|
||||
|
||||
void qemu_system_guest_crashloaded(GuestPanicInformation *info)
|
||||
{
|
||||
qemu_log_mask(LOG_GUEST_ERROR, "Guest crash loaded");
|
||||
|
||||
qapi_event_send_guest_crashloaded(GUEST_PANIC_ACTION_RUN,
|
||||
!!info, info);
|
||||
|
||||
if (info) {
|
||||
qapi_free_GuestPanicInformation(info);
|
||||
}
|
||||
}
|
||||
|
||||
void qemu_system_reset_request(ShutdownCause reason)
|
||||
{
|
||||
if (no_reboot && reason != SHUTDOWN_CAUSE_SUBSYSTEM_RESET) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue