From: "Annie.li" <annie.li@oracle.com>
To: "Philippe Mathieu-Daudé" <philmd@linaro.org>,
qemu-devel@nongnu.org, imammedo@redhat.com
Cc: miguel.luis@oracle.com
Subject: Re: [RFC PATCH 01/11] acpi: hmp/qmp: Add hmp/qmp support for system_sleep
Date: Tue, 5 Dec 2023 09:43:57 -0500 [thread overview]
Message-ID: <82eae840-1513-18db-d75a-ef758bac6b87@oracle.com> (raw)
In-Reply-To: <f873dd1e-b5ee-452e-9dd7-2f25ef2ada7b@linaro.org>
Hi Philippe,
On 12/5/2023 4:44 AM, Philippe Mathieu-Daudé wrote:
> Hi Annie,
>
> On 5/12/23 01:23, Annie Li wrote:
>> Following hmp/qmp commands are implemented for pressing virtual
>> sleep button,
>>
>> hmp: system_sleep
>> qmp: { "execute": "system_sleep" }
>>
>> These commands put the guest into suspend or other power states
>> depending on the power settings inside the guest.
>>
>> Signed-off-by: Annie Li <annie.li@oracle.com>
>> ---
>> hmp-commands.hx | 14 ++++++++++++++
>> hw/core/machine-hmp-cmds.c | 5 +++++
>> hw/core/machine-qmp-cmds.c | 9 +++++++++
>> include/monitor/hmp.h | 1 +
>> qapi/machine.json | 18 ++++++++++++++++++
>> qapi/pragma.json | 1 +
>> 6 files changed, 48 insertions(+)
>
>
>> index b6d634b30d..3ac69df92f 100644
>> --- a/qapi/machine.json
>> +++ b/qapi/machine.json
>> @@ -297,6 +297,24 @@
>> ##
>> { 'command': 'system_reset' }
>> +##
>> +# @system_sleep:
>
> @since 9.0
Nod
>
>> +#
>> +# Requests that a guest perform a ACPI sleep transition by pushing a
>> virtual
>> +# sleep button.
>> +#
>> +# Notes: A guest may or may not respond to this command. This command
>> +# returning does not indicate that a guest has accepted the
>> request
>> +# or that it has gone to sleep.
>> +#
>> +# Example:
>> +#
>> +# -> { "execute": "system_sleep" }
>> +# <- { "return": {} }
>> +#
>> +##
>> +{ 'command': 'system_sleep' }
>
> Do we want a 'mode' argument, starting here with control_method?
As what has been discussed previously in the following thread,
https://lore.kernel.org/all/20210920095316.2dd133be@redhat.com/T/#mfe24f89778020deeacfe45083f3eea3cf9f55961
the Control Method Sleep button can be shared among various
architectures. It is very likely that there will be one type of sleep
button(Control Method) implemented, so the extra argument
isn't necessary.
Thanks
Annie
>
>> +
>> ##
>> # @system_powerdown:
>> #
next prev parent reply other threads:[~2023-12-05 14:44 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-05 0:21 [RFC PATCH 00/11] Support ACPI Control Method Sleep button Annie Li
2023-12-05 0:23 ` [RFC PATCH 01/11] acpi: hmp/qmp: Add hmp/qmp support for system_sleep Annie Li
2023-12-05 9:44 ` Philippe Mathieu-Daudé
2023-12-05 14:43 ` Annie.li [this message]
2023-12-05 20:34 ` Markus Armbruster
2023-12-05 21:46 ` Annie.li
2023-12-22 12:37 ` Markus Armbruster
2023-12-22 18:39 ` Annie.li
2023-12-05 0:26 ` [RFC PATCH 02/11] acpi: Implement control method sleep button Annie Li
2023-12-05 0:26 ` [RFC PATCH 03/11] test/acpi: allow DSDT table changes Annie Li
2023-12-05 0:27 ` [RFC PATCH 04/11] acpi: Support Control Method sleep button for x86 Annie Li
2023-12-05 0:27 ` [RFC PATCH 05/11] tests/acpi/bios-tables-test: update DSDT tables for Control Method Sleep button Annie Li
2023-12-05 0:28 ` [RFC PATCH 06/11] acpi: Send the GPE event of suspend and wakeup for x86 Annie Li
2023-12-05 0:28 ` [RFC PATCH 07/11] hw/acpi: Add ACPI GED support for the sleep event Annie Li
2023-12-05 0:29 ` [RFC PATCH 08/11] tests/acpi: allow FACP and DSDT table changes for arm/virt Annie Li
2023-12-05 0:29 ` [RFC PATCH 09/11] hw/arm: enable sleep support " Annie Li
2023-12-05 0:30 ` [RFC PATCH 10/11] tests/acpi: Update FACP and DSDT tables for sleep button Annie Li
2023-12-05 0:31 ` [RFC PATCH 11/11] arm/virt: enable sleep support Annie Li
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=82eae840-1513-18db-d75a-ef758bac6b87@oracle.com \
--to=annie.li@oracle.com \
--cc=imammedo@redhat.com \
--cc=miguel.luis@oracle.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@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 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).