From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MOZXS-000381-Oy for qemu-devel@nongnu.org; Wed, 08 Jul 2009 11:58:30 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MOZXO-00034j-N7 for qemu-devel@nongnu.org; Wed, 08 Jul 2009 11:58:30 -0400 Received: from [199.232.76.173] (port=56723 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MOZXO-00034a-I2 for qemu-devel@nongnu.org; Wed, 08 Jul 2009 11:58:26 -0400 Received: from e36.co.us.ibm.com ([32.97.110.154]:39422) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1MOZXO-0003yy-2X for qemu-devel@nongnu.org; Wed, 08 Jul 2009 11:58:26 -0400 Received: from d03relay03.boulder.ibm.com (d03relay03.boulder.ibm.com [9.17.195.228]) by e36.co.us.ibm.com (8.13.1/8.13.1) with ESMTP id n68FuoIq016454 for ; Wed, 8 Jul 2009 09:56:50 -0600 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay03.boulder.ibm.com (8.13.8/8.13.8/NCO v9.2) with ESMTP id n68FwDS4106424 for ; Wed, 8 Jul 2009 09:58:15 -0600 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id n68FwBD5005282 for ; Wed, 8 Jul 2009 09:58:11 -0600 Date: Wed, 8 Jul 2009 10:58:10 -0500 From: Ryan Harper Subject: Re: [Qemu-devel] [PATCH][RESEND] Add monitor command for system_reboot Message-ID: <20090708155810.GU11590@us.ibm.com> References: <20090707192631.GQ11590@us.ibm.com> <20090708075601.GJ28046@redhat.com> <4A549990.2060205@us.ibm.com> <20090708132623.GN26640@redhat.com> <4A54A367.3010603@us.ibm.com> <20090708135607.GO26640@redhat.com> <20090708154349.GT11590@us.ibm.com> <4A54C012.2080003@us.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4A54C012.2080003@us.ibm.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Ryan Harper , qemu-devel@nongnu.org, Gleb Natapov * Anthony Liguori [2009-07-08 10:50]: > Ryan Harper wrote: > >>That suffers from the same problem as a system_reboot command in that > >>the guest may never start the shutdown. If that's an acceptable > >>limitation, then we might as well implement it directly in QEMU as > >>system_reboot so its easily available to everyone. Make 'system_reboot' > >>take an optional timeout arg (default to 60 seconds) after which it > >>cancels its plans. > >> > > > >This seems the most reasonable thing to me. As already mentioned, > >system_powerdown already is non-deterministic since the guest could > >ignore the ACPI event. > > > > It's a different class of non-determinism though. With > system_powerdown, you make a request to the guest. You don't know > whether the guest will comply with the request. The same level of > non-determinism exists with ballooning. > > With system_reboot, you're taking an action (system_reset) and what's > not deterministic is whether you're taking that action based on what > someone requested on the monitor (system_reboot) verses whether you're > taking that action based on something the user did (shutdown). In the > later case, you're action is functionally incorrect. Only if the shutdown from the user occurs in timeout period. So, yes, it's still present, but the window of the behavior can be much smaller. I still think this is a reasonable approach even with that window. -- Ryan Harper Software Engineer; Linux Technology Center IBM Corp., Austin, Tx ryanh@us.ibm.com