* [Qemu-devel] Unix signal to send ACPI-shutdown to Guest
@ 2018-04-28 22:59 Andrew Wood
2018-05-08 10:11 ` Stefan Hajnoczi
0 siblings, 1 reply; 2+ messages in thread
From: Andrew Wood @ 2018-04-28 22:59 UTC (permalink / raw)
To: qemu-devel
Ive been looking into the possibility of using a unix signal to send an
acpi shutdown request to a VM, and came across a posting on this l in
March 1. See
https://lists.nongnu.org/archive/html/qemu-devel/2017-03/msg04169.html
To summarise to refresh memories there was a patch proposed using
SIGINT followed by discussion as to why SIGINT wasnt ideal because it
would cause regressions for anyone relying on the existing handling of
SIGINT, and various other signals were considered including HUP & USR1 &
USR2 all of which are already used for something else.
Is SIGPWR a suitable candidate, I have made a patch to use SIGPWR but as
Im new to QEMUs internals Im not sure if there are any circumstances in
which an alternative handler is registered for SIGPWR which might conflict?
Regards
Andrew
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] Unix signal to send ACPI-shutdown to Guest
2018-04-28 22:59 [Qemu-devel] Unix signal to send ACPI-shutdown to Guest Andrew Wood
@ 2018-05-08 10:11 ` Stefan Hajnoczi
0 siblings, 0 replies; 2+ messages in thread
From: Stefan Hajnoczi @ 2018-05-08 10:11 UTC (permalink / raw)
To: Andrew Wood; +Cc: qemu-devel
[-- Attachment #1: Type: text/plain, Size: 1266 bytes --]
On Sat, Apr 28, 2018 at 11:59:41PM +0100, Andrew Wood via Qemu-devel wrote:
> Ive been looking into the possibility of using a unix signal to send an acpi
> shutdown request to a VM, and came across a posting on this l in March 1.
> See https://lists.nongnu.org/archive/html/qemu-devel/2017-03/msg04169.html
>
>
> To summarise to refresh memories there was a patch proposed using SIGINT
> followed by discussion as to why SIGINT wasnt ideal because it would cause
> regressions for anyone relying on the existing handling of SIGINT, and
> various other signals were considered including HUP & USR1 & USR2 all of
> which are already used for something else.
>
> Is SIGPWR a suitable candidate, I have made a patch to use SIGPWR but as Im
> new to QEMUs internals Im not sure if there are any circumstances in which
> an alternative handler is registered for SIGPWR which might conflict?
A quick grep of the Linux kernel code suggests that SIGPWR is very
rarely raised by the kernel. It's only sent to init on s390 and Silicon
Graphics SN systems. QEMU could use the signal on Linux without risk of
collision.
It's worth sending a patch. Here are the patch submission guidelines:
https://wiki.qemu.org/Contribute/SubmitAPatch
Stefan
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 455 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-05-08 10:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-28 22:59 [Qemu-devel] Unix signal to send ACPI-shutdown to Guest Andrew Wood
2018-05-08 10:11 ` Stefan Hajnoczi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).