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

[Xen-devel] Re: one question to PHYSDEVOP_manage_pci_remove

The idea was to use PHYSDEVOP_manage_pci_{add,remove} for
hot-pluggable devices and SR-IOV or ARI capable devices.  In general,
when a new PCI device function is added or removed during runtime,
dom0 will invoke the hypercall to register or unrigister the
corresponding struct pci_dev within Xen.

Xen clears the VT-d entry because the device is about to be removed
from the system --- either physically removed or just completely
disabled by dom0.  The device is forcibly removed from the guest if it
is assigned to one.  It is up to dom0 to do the actual device
reassignment.  Although the device can not access any host memory I
suppose it would not hurt to also do deassign_device() when the device
is removed.  This would tear down the IOMMU page tables for the domain
if they are not needed anymore.

        eSk


[Yunhong Jiang]
> Hi, Espen, when I'm working on the MSI lock issue, I have one
> question to PHYSDEVOP_manage_pci_remove. From the kernel, seems it
> will happen for PCI device remove. Is it target only for pci
> hotplug?

> I asked this because I noticed that in current code, it will always
> clear the VT-d entry, no matter if the device is owned by other
> domain, I'm not sure if it reqiures the device is not owned by a
> guest (maybe except dom0).


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

<Prev in Thread] Current Thread [Next in Thread>