提交 b5d51214 编写于 作者: K Konrad Rzeszutek Wilk 提交者: David Vrabel

xen/pciback: Include the domain id if removing the device whilst still in use

Cleanup the function a bit - also include the id of the
domain that is using the device.
Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Reviewed-by: NDavid Vrabel <david.vrabel@citrix.com>
Signed-off-by: NDavid Vrabel <david.vrabel@citrix.com>
上级 ac801022
...@@ -553,12 +553,14 @@ static void pcistub_remove(struct pci_dev *dev) ...@@ -553,12 +553,14 @@ static void pcistub_remove(struct pci_dev *dev)
spin_unlock_irqrestore(&pcistub_devices_lock, flags); spin_unlock_irqrestore(&pcistub_devices_lock, flags);
if (found_psdev) { if (found_psdev) {
dev_dbg(&dev->dev, "found device to remove - in use? %p\n", dev_dbg(&dev->dev, "found device to remove %s\n",
found_psdev->pdev); found_psdev->pdev ? "- in-use" : "");
if (found_psdev->pdev) { if (found_psdev->pdev) {
pr_warn("****** removing device %s while still in-use! ******\n", int domid = xen_find_device_domain_owner(dev);
pci_name(found_psdev->dev));
pr_warn("****** removing device %s while still in-use by domain %d! ******\n",
pci_name(found_psdev->dev), domid);
pr_warn("****** driver domain may still access this device's i/o resources!\n"); pr_warn("****** driver domain may still access this device's i/o resources!\n");
pr_warn("****** shutdown driver domain before binding device\n"); pr_warn("****** shutdown driver domain before binding device\n");
pr_warn("****** to other drivers or domains\n"); pr_warn("****** to other drivers or domains\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册