On some systems the config generator permissively maps huge chunks of
PCI Bus MMIO space. This area needs to be intercepted by the hypervisor,
as parts of ivshmem-net devices may be behind that area.

Hence, ignore such regions.

Signed-off-by: Andrej Utz <[email protected]>
---
 pyjailhouse/sysfs_parser.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/pyjailhouse/sysfs_parser.py b/pyjailhouse/sysfs_parser.py
index f48f249f..4a06ccdc 100644
--- a/pyjailhouse/sysfs_parser.py
+++ b/pyjailhouse/sysfs_parser.py
@@ -105,6 +105,10 @@ def parse_iomem(pcidevices):
 
     ret = []
     for r in regions:
+        # filter empty PCI buses
+        if r.typestr.startswith('PCI Bus'):
+            continue
+
         append_r = True
         # filter the list for MSI-X pages
         for d in pcidevices:
-- 
2.22.0

-- 
You received this message because you are subscribed to the Google Groups 
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jailhouse-dev/20190702135846.20045-1-andrej.utz%40st.oth-regensburg.de.
For more options, visit https://groups.google.com/d/optout.

Reply via email to