Skip to contentSkip to conversation

xend: call pci_device_configure on the stubdom

PATCH New Stefano Stabellini 1 participant 1 message Oct 12, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 xend: call pci_device_configure on the stubdom

Whenever pci_device_configure is called on a guest that has a stubdom, call pci_device_configure on the stubdom as well.

---

tools/python/xen/xend/XendDomainInfo.py +7 -0
diff -r 7dfb1cb1050e tools/python/xen/xend/XendDomainInfo.py
@@ -855,6 +855,13 @@
         dev_config = pci_convert_sxp_to_dict(dev_sxp)
         dev = dev_config['devs'][0]
 
+        dom_list = xstransact.List('/local/domain')
+        for d in dom_list:
+            target = xstransact.Read('/local/domain/' + d + '/target')
+            if target is not None and int(target) is self.domid :
+                from xen.xend import XendDomain
+                XendDomain.instance().domain_lookup(int(d)).pci_device_configure(dev_sxp[:])
+
         # Do HVM specific processing
         if self.info.is_hvm():
             if pci_state == 'Initialising':