|
From: | Paolo Bonzini |
Subject: | Re: [PATCH v2 2/4] vl: Add option to avoid stopping VM upon guest panic |
Date: | Thu, 10 Dec 2020 03:43:18 +0100 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.0 |
On 09/12/20 18:52, Alejandro Jimenez wrote:
- vm_stop(RUN_STATE_GUEST_PANICKED); + + if (pause_on_panic) { + qapi_event_send_guest_panicked(GUEST_PANIC_ACTION_PAUSE, + !!info, info); + vm_stop(RUN_STATE_GUEST_PANICKED); + } else { + qapi_event_send_guest_panicked(GUEST_PANIC_ACTION_RUN, + !!info, info); + } + if (!no_shutdown) { qapi_event_send_guest_panicked(GUEST_PANIC_ACTION_POWEROFF, !!info, info);
The "if" below suggests making -action panic's argument a tri-state (none/pause/poweroff; default is poweroff and -no-shutdown becomes equivalent to -action shutdown=pause,panic=pause).
In principle debug and reset could be supported as well, so maybe add a TODO comment.
Paolo
[Prev in Thread] | Current Thread | [Next in Thread] |