[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2] event: Add source information to SHUTDOWN

From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v2] event: Add source information to SHUTDOWN
Date: Thu, 20 Apr 2017 18:12:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux)

Eric Blake <address@hidden> writes:

> On 04/20/2017 07:09 AM, Daniel P. Berrange wrote:
>>>> +++ b/qapi/event.json
>>>> @@ -10,6 +10,10 @@
>>>>  # Emitted when the virtual machine has shut down, indicating that qemu is
>>>>  # about to exit.
>>>>  #
>>>> +# @guest: If true, the shutdown was triggered by a guest request (such as
>>>> +# executing a halt instruction) rather than a host request (such as 
>>>> sending
>>>> +# qemu a SIGINT). (since 2.10)
>>>> +#
>>> "executing a halt instruction" suggests "halt" is a machine instruction.
> Which is indeed what most of the places I patched to pass 'true' are
> emulating - the machine halt instruction.
>>> I think you mean /usr/sbin/halt.  Suggest something like "executing a
>>> halt command".
>> Well technically /usr/sbin/halt just terminates all processes / kernel and
>> halts CPUs, but the virtual machine is still active (and a 'reset' in the
>> monitor can start it again. /usr/sbin/poweroff is what actually does the
>> ACPI poweroff to trigger QEMU to exit[1]
> I'm thinking of this wording:
> triggered by a guest request (such as the guest running
> /usr/sbin/poweroff to trigger an ACPI shutdown or machine halt instruction)

A quick glance at the patch suggests the instructions in question are
typically writes to some device register.  I wouldn't call them "halt
instructions", in particular since there's the x86 "hlt" instruction
that does something else.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]