aboutsummaryrefslogtreecommitdiffstats
path: root/tools/libxl/libxl_pci.c
diff options
context:
space:
mode:
authorIan Campbell <ian.campbell@citrix.com>2011-12-09 12:01:16 +0000
committerIan Campbell <ian.campbell@citrix.com>2011-12-09 12:01:16 +0000
commit18f93842ac3c2ca4e985497ea5e9f4d7e8fdfeaf (patch)
tree4dac307cf84114ed760efa7a0dba4097d3342c82 /tools/libxl/libxl_pci.c
parent0d819a81abd35d31a3377ec23c356e590d3d4c88 (diff)
downloadxen-18f93842ac3c2ca4e985497ea5e9f4d7e8fdfeaf.tar.gz
xen-18f93842ac3c2ca4e985497ea5e9f4d7e8fdfeaf.tar.bz2
xen-18f93842ac3c2ca4e985497ea5e9f4d7e8fdfeaf.zip
libxl: fix cold plugged PCI devices with stubdomains
Since 23565:72eafe80ebc1 the xenstore entries for the stubdomain's PCI were never created and therefore the stubdom ends up waiting forever for the devices which it has been asked to insert to show up. Since the stubdomain is already running when we call the libxl_device_pci_add loop in do_domain_create we should treat it as if "starting == 0". Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson.citrix.com> Committed-by: Ian Jackson <ian.jackson.citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Diffstat (limited to 'tools/libxl/libxl_pci.c')
-rw-r--r--tools/libxl/libxl_pci.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/libxl/libxl_pci.c b/tools/libxl/libxl_pci.c
index 120c2397c1..8b2a1c5b77 100644
--- a/tools/libxl/libxl_pci.c
+++ b/tools/libxl/libxl_pci.c
@@ -814,7 +814,8 @@ int libxl__device_pci_add(libxl__gc *gc, uint32_t domid, libxl_device_pci *pcide
stubdomid = libxl_get_stubdom_id(ctx, domid);
if (stubdomid != 0) {
libxl_device_pci pcidev_s = *pcidev;
- rc = do_pci_add(gc, stubdomid, &pcidev_s, starting);
+ /* stubdomain is always running by now, even at create time */
+ rc = do_pci_add(gc, stubdomid, &pcidev_s, 0);
if ( rc )
goto out;
}