From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O6jLQ-0000Xv-Nw for qemu-devel@nongnu.org; Tue, 27 Apr 2010 07:52:52 -0400 Received: from [140.186.70.92] (port=46005 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O6jLK-0000UZ-7E for qemu-devel@nongnu.org; Tue, 27 Apr 2010 07:52:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O6jL8-0002x6-0f for qemu-devel@nongnu.org; Tue, 27 Apr 2010 07:52:41 -0400 Received: from mail-ew0-f227.google.com ([209.85.219.227]:43240) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O6jL7-0002wj-Dn for qemu-devel@nongnu.org; Tue, 27 Apr 2010 07:52:33 -0400 Received: by ewy27 with SMTP id 27so3925622ewy.10 for ; Tue, 27 Apr 2010 04:52:32 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <4BD6CFFD.6070308@redhat.com> Date: Tue, 27 Apr 2010 13:52:29 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1272296853-30285-1-git-send-email-lcapitulino@redhat.com> <1272296853-30285-6-git-send-email-lcapitulino@redhat.com> <4BD5D234.2030508@codemonkey.ws> <20100426152238.5ece1c15@redhat.com> <4BD5DAA2.4050206@codemonkey.ws> <20100426155303.2c381ff7@redhat.com> <4BD5E2BB.8000105@codemonkey.ws> <4BD5E51A.9070402@web.de> <4BD5E5E4.8000609@codemonkey.ws> <20100426164448.679a4d19@redhat.com> In-Reply-To: <20100426164448.679a4d19@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 5/9] Monitor: Return before exiting with 'quit' List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Luiz Capitulino Cc: Jan Kiszka , qemu-devel@nongnu.org On 04/26/2010 09:44 PM, Luiz Capitulino wrote: > + qemu_system_exit_request(); Untested suggestion: why add qemu_system_exit_request, exit_requested, and a hook in the main loop? You can do instead no_shutdown = 0; qemu_system_shutdown_request(); which will actually call quit_timers() and net_cleanup() properly unlike a blind exit(0). Alternatively, just give an error when "quit"-ting from QMP and keep the current behavior for non-QMP. This way you do not provide two ways to do the same thing. People will have to avoid -no-shutdown (I don't see how it is useful from QMP) and they will be able to use the "shutdown" monitor command. Paolo