From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NuypC-0005Dm-If for qemu-devel@nongnu.org; Thu, 25 Mar 2010 21:59:02 -0400 Received: from [140.186.70.92] (port=53844 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NuypA-0005CZ-G5 for qemu-devel@nongnu.org; Thu, 25 Mar 2010 21:59:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Nuyp8-00081h-Ur for qemu-devel@nongnu.org; Thu, 25 Mar 2010 21:59:00 -0400 Received: from mx1.redhat.com ([209.132.183.28]:4769) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Nuyp8-00081R-NU for qemu-devel@nongnu.org; Thu, 25 Mar 2010 21:58:58 -0400 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o2Q1wsq3003218 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 25 Mar 2010 21:58:55 -0400 Date: Fri, 26 Mar 2010 07:27:27 +0530 From: Amit Shah Subject: Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add Message-ID: <20100326015727.GE8111@amit-x200.redhat.com> References: <1269442173-18421-5-git-send-email-amit.shah@redhat.com> <1269442173-18421-6-git-send-email-amit.shah@redhat.com> <1269442173-18421-7-git-send-email-amit.shah@redhat.com> <1269442173-18421-8-git-send-email-amit.shah@redhat.com> <1269442173-18421-9-git-send-email-amit.shah@redhat.com> <1269442173-18421-10-git-send-email-amit.shah@redhat.com> <1269442173-18421-11-git-send-email-amit.shah@redhat.com> <20100324173415.63e31bd0@redhat.com> <20100325034717.GA23562@amit-x200.redhat.com> <20100325153406.69fbc717@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100325153406.69fbc717@redhat.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Luiz Capitulino Cc: qemu list , "Michael S. Tsirkin" , Gerd Hoffmann , Juan Quintela On (Thu) Mar 25 2010 [15:34:06], Luiz Capitulino wrote: > On Thu, 25 Mar 2010 09:17:17 +0530 > Amit Shah wrote: > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > > On Wed, 24 Mar 2010 20:19:28 +0530 > > > Amit Shah wrote: > > > > > > > When adding a port or a device to the guest fails, management software > > > > might be interested in knowing and then cleaning up the host-side of the > > > > port. Introduce QMP events to signal such errors. > > > > > > I'm completely unfamiliar with virtio-serial, so let me ask: how are ports > > > added? I'd expect the command performing this operation to fail in this case. > > > > If adding the port fails in qemu, then the command will fail. However if > > adding the port in the guest fails, we raise this QMP event. Adding in > > the guest could fail because of several reasons, like ENOMEM. In this > > case, the mgmt might want to hot-unplug the port from qemu so that > > resources are freed and also apps are notified of guest side not ready. > > Ok, what about a disconnect? Does virtio-serial have this kind of action? In case of guest disconnect, an event is sent by the guest to the host and the host sends it to the app. A qmp event is not triggered, one can be, if desired. Amit