WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH, RFC]: qemu: hang-free/error-tolerant PCI hot-plu

To: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH, RFC]: qemu: hang-free/error-tolerant PCI hot-plug protocol
From: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Date: Fri, 30 Jul 2010 15:45:17 +0100
Cc: Xen Devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, "Gianni Tedesco \(3P\)" <gianni.tedesco@xxxxxxxxxx>
Delivery-date: Fri, 30 Jul 2010 07:46:16 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <19538.54845.682500.241310@xxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <1280426058.1723.2266.camel@xxxxxxxxxxxxxxxxxxxxxx> <19538.54845.682500.241310@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Alpine 2.00 (DEB 1167 2008-08-23)
On Fri, 30 Jul 2010, Ian Jackson wrote:
> Gianni Tedesco writes ("[Xen-devel] [PATCH, RFC]: qemu: 
> hang-free/error-tolerant PCI hot-plug protocol"):
> > The interface for PCI hotplug is flexible enough to shoot ones-self in
> > the foot. It is possible to try to insert a PCI device in to a slot
> > already occupied by a qemu emulated device (NIC, PIIX, ISA-bridge, etc.)
> > In this case qemu (wisely) refuses to do the hotplug. Since there is no
> > way for a toolstack to query qemu's pci device layout there is no way to
> > check for this ahead of time. In this case the toolstack must wait for
> > device-model state to change to pci-inserted which never happens.
> 
> Hrm.
> 
> > I propose that when qemu decides not to hot-plug a device that it raise
> > the "pci-inserted" status anyway. The tools must then check the
> > "parameter" key in xenbus for a non-error string. In other words:
> 
> Why do this rather than a new status "pci-insert-failed" ?  How does
> this affect existing toolstacks ?
> 

A new return status would cause existing toolstacks to keep waiting
until the timeout expires.
On the other hand Gianni's approach is backward compatible.

> > --- a/hw/piix4acpi.c
> > +++ b/hw/piix4acpi.c
> 
> I haven't looked at the code near here.  Does qemu log anything ?  If
> so then the corresponding toolstack patches should say "consult qemu
> logfile".  Otherwise perhaps qemu should.

Consulting logfiles in case of errors is always a good idea, but we
should be able to detect that there was an error first, without waiting
for a timeout to expire.


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel