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] xl: pci completion error

To: Sergey Tovpeko <tsv.devel@xxxxxxxxx>
Subject: Re: [Xen-devel] xl: pci completion error
From: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Date: Wed, 6 Oct 2010 14:54:05 +0100
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <Stefano.Stabellini@xxxxxxxxxxxxx>
Delivery-date: Wed, 06 Oct 2010 06:54:39 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4CAC74DD.3030703@xxxxxxxxx>
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: <4CAB0E9A.5050507@xxxxxxxxx> <alpine.DEB.2.00.1010061136220.2440@kaball-desktop> <4CAC74DD.3030703@xxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Alpine 2.00 (DEB 1167 2008-08-23)
On Wed, 6 Oct 2010, Sergey Tovpeko wrote:
> The guest is Windows XP sp2 32 bit.
> 
> When I do pci hot-unplug on the fly
> xl pci-detach 11:0b.0
> the guest detaches the pci card correctly with 'pci-removed' signal, but 
> on the shutdown, it doesn't.
> 
> In the code the flow is the following:
> qemu-dm receives the 'pci-rem' command and sends the SCI interrupt to 
> the guest. I think guest should catch this interrupt and write to the 
> magic ACPI port that causes qemu-dm send 'pci-removed' signal.
> 
> On guest shutdown,  libxl sends 'pci-rem' command to qemu-dm and waits 
> for the answer.
> I suppose, by the time 'pci-rem' signal my guest have finished its work, 
> and doesn't react on SCI interrupt. As a result libxl doesn't receive 
> pci-removed signal.
> 
> It's my observation.
> 

We could probably benefit from a boolean "force" parameter to do_pci_remove
and libxl_device_pci_remove, that would cause do_pci_remove not to
return if libxl__wait_for_device_model returns error.
Of course libxl_device_pci_remove would be called with force=1 by
libxl_device_pci_shutdown.
Gianni, what do you think?

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