From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MOWs9-0008S7-PE for qemu-devel@nongnu.org; Wed, 08 Jul 2009 09:07:42 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MOWs3-0008K4-TL for qemu-devel@nongnu.org; Wed, 08 Jul 2009 09:07:40 -0400 Received: from [199.232.76.173] (port=43991 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MOWs1-0008Jm-LI for qemu-devel@nongnu.org; Wed, 08 Jul 2009 09:07:35 -0400 Received: from mail-px0-f201.google.com ([209.85.216.201]:47008) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MOWs1-0004Ou-5Z for qemu-devel@nongnu.org; Wed, 08 Jul 2009 09:07:33 -0400 Received: by pxi39 with SMTP id 39so2058951pxi.4 for ; Wed, 08 Jul 2009 06:07:32 -0700 (PDT) Message-ID: <4A549A0F.5040902@codemonkey.ws> Date: Wed, 08 Jul 2009 08:07:27 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH][RESEND] Add monitor command for system_reboot References: <20090707192631.GQ11590@us.ibm.com> <4A54294C.1030409@redhat.com> In-Reply-To: <4A54294C.1030409@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: Anthony Liguori , Ryan Harper , qemu-devel@nongnu.org Avi Kivity wrote: > On 07/07/2009 10:26 PM, Ryan Harper wrote: >> Add a new monitor command (system_reboot) for a soft reboot which uses >> system_powerdown to trigger ACPI shutdown in the guest and once shutdown >> is complete, trigger a reset instead of exiting qemu. >> >> Depends on commit a6d6552426dcbf726e5549f08b70c9318d6be14b which enabled >> ACPI power button support. >> >> V2: >> -added reset handler to lower the reboot flag on reset. >> >> Tested with: >> - Ubuntu 9.04 64-bit guest. >> - SLES 10 SP2 32-bit guest. >> - RHEL 5.3 32 and 64 bit guests. >> >> > > I think a combination of system_powerdown, avoiding exit on shutdown, > and system_reset is more flexible as it allows the controller to > modify the guest before rebooting it. You need notification that the shutdown has occurred. That's the only bit we're missing today. It's still not perfect though. libvirt does system_powerdown, guest completely ignores it, user decides to power off, libvirt cannot tell the difference between user requested power off and ACPI driven power down. Regards, Anthony Liguori