From: Markus Armbruster <armbru@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: "QEMU Developers" <qemu-devel@nongnu.org>,
"Nicholas Piggin" <npiggin@gmail.com>,
"Daniel Henrique Barboza" <danielhb413@gmail.com>,
"Cédric Le Goater" <clg@kaod.org>,
"David Gibson" <david@gibson.dropbear.id.au>,
"Harsh Prateek Bora" <harshpb@linux.ibm.com>,
qemu-ppc <qemu-ppc@nongnu.org>,
"Paolo Bonzini" <pbonzini@redhat.com>
Subject: Re: spapr watchdog vs watchdog_perform_action() / QMP watchdog-set-action
Date: Fri, 26 Jan 2024 21:49:00 +0100 [thread overview]
Message-ID: <87le8byg5f.fsf@pond.sub.org> (raw)
In-Reply-To: <CAFEAcA_KjSgt-oC=d2m6WAdqoRsUcs1W_ji7Ng2fgVjxAWLZEw@mail.gmail.com> (Peter Maydell's message of "Fri, 26 Jan 2024 15:23:44 +0000")
Peter Maydell <peter.maydell@linaro.org> writes:
> Hi; one of the "bitesized tasks" we have listed is to convert
> watchdog timers which directly call qemu_system_reset_request() on
> watchdog timeout to call watchdog_perform_action() instead. This
> means they honour the QMP commands that let the user specifiy
> the behaviour on watchdog expiry:
> https://www.qemu.org/docs/master/interop/qemu-qmp-ref.html#qapidoc-141
> https://www.qemu.org/docs/master/interop/qemu-qmp-ref.html#qapidoc-129
> (choices include reset, power off the system, do nothing, etc).
>
> There are only a few remaining watchdogs that don't use the
> watchdog_perform_action() function. In most cases the change
> is obvious and easy: just make them do that instead of calling
> qemu_system_reset_request(SHUTDOWN_CAUSE_GUEST_RESET).
>
> However, the hw/watchdog/spapr_watchdog.c case is trickier. As
> far as I can tell from the sources, this is a watchdog set up via
> a hypercall, and the guest makes a choice of "power off, restart,
> or dump and restart" for its on-expiry action.
>
> What should this watchdog's interaction with the watchdog-set-action
> QMP command be? If the user says "do X" and the guest says "do Y",
> which do we do? (With the current code, we always honour what
> the guest asks for and ignore what the user asks for.)
Gut reaction: when the user says "do X", the guest should not get a say.
But one of the values of X could be "whatever the guest says".
> (The bitesized task for watchdog_perform_action() is
> https://gitlab.com/qemu-project/qemu/-/issues/2124 . For the
> purposes of this email thread I'm only after a concrete decision
> about what we think the right thing is, not for any code. Then
> I can write that up in the bug for potential new contributors.)
>
> thanks
> -- PMM
next prev parent reply other threads:[~2024-01-26 20:50 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-26 15:23 spapr watchdog vs watchdog_perform_action() / QMP watchdog-set-action Peter Maydell
2024-01-26 20:49 ` Markus Armbruster [this message]
2024-01-27 13:08 ` Peter Maydell
2024-01-29 3:58 ` David Gibson
2024-02-22 14:47 ` Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87le8byg5f.fsf@pond.sub.org \
--to=armbru@redhat.com \
--cc=clg@kaod.org \
--cc=danielhb413@gmail.com \
--cc=david@gibson.dropbear.id.au \
--cc=harshpb@linux.ibm.com \
--cc=npiggin@gmail.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.