qemu-e2k/tests/libqos
David Gibson c711369087 libqos: Correct error in PCI hole sizing for spapr
In pci-spapr.c (as in pci-pc.c from which it was derived), the
pci_hole_start/pci_hole_size and pci_iohole_start/pci_iohole_size pairs[1]
essentially define the region of PCI (not CPU) addresses in which MMIO
or PIO BARs respectively will be allocated.

The size value is relative to the start value.  But in pci-spapr.c it is
set to the entire size of the window supported by the (emulated) hardware,
but the start values are *not* at the beginning of the emulated windows.

That means if you tried to map enough PCI BARs, we'd messily overrun the
IO windows, instead of failing in iomap as we should.

This patch corrects this by calculating the hole sizes from the location
of the window in PCI space and the hole start.

[1] Those are bad names, but that's a problem for another time.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Laurent Vivier <lvivier@redhat.com>
2016-10-16 12:03:09 +11:00
..
ahci.c libqos: add PCI management in qtest_vboot()/qtest_shutdown() 2016-10-06 16:15:53 +11:00
ahci.h Clean up ill-advised or unusual header guards 2016-07-12 16:20:46 +02:00
fw_cfg.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
fw_cfg.h all: Clean up includes 2016-02-23 12:43:05 +00:00
i2c-imx.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
i2c-omap.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
i2c.c tests: Clean up includes 2016-02-16 14:29:27 +00:00
i2c.h all: Clean up includes 2016-02-23 12:43:05 +00:00
libqos-pc.c libqos: use generic qtest_shutdown() 2016-10-06 16:15:53 +11:00
libqos-pc.h Clean up ill-advised or unusual header guards 2016-07-12 16:20:46 +02:00
libqos-spapr.c libqos: use generic qtest_shutdown() 2016-10-06 16:15:53 +11:00
libqos-spapr.h libqos: define SPAPR libqos functions 2016-09-23 10:29:40 +10:00
libqos.c libqos: use generic qtest_shutdown() 2016-10-06 16:15:53 +11:00
libqos.h libqos: use generic qtest_shutdown() 2016-10-06 16:15:53 +11:00
malloc-generic.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
malloc-generic.h libqos: Add malloc generic 2015-03-10 14:02:20 +01:00
malloc-pc.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
malloc-pc.h libqos: Convert malloc-pc allocator to a generic allocator 2015-01-13 11:47:57 +00:00
malloc-spapr.c libqos: define SPAPR libqos functions 2016-09-23 10:29:40 +10:00
malloc-spapr.h libqos: define SPAPR libqos functions 2016-09-23 10:29:40 +10:00
malloc.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
malloc.h all: Clean up includes 2016-02-23 12:43:05 +00:00
pci-pc.c libqos: add PCI management in qtest_vboot()/qtest_shutdown() 2016-10-06 16:15:53 +11:00
pci-pc.h libqos: add PCI management in qtest_vboot()/qtest_shutdown() 2016-10-06 16:15:53 +11:00
pci-spapr.c libqos: Correct error in PCI hole sizing for spapr 2016-10-16 12:03:09 +11:00
pci-spapr.h libqos: add PPC64 PCI support 2016-10-06 16:15:40 +11:00
pci.c libqos: add PPC64 PCI support 2016-10-06 16:15:40 +11:00
pci.h all: Clean up includes 2016-02-23 12:43:05 +00:00
rtas.c libqos: add PPC64 PCI support 2016-10-06 16:15:40 +11:00
rtas.h libqos: add PPC64 PCI support 2016-10-06 16:15:40 +11:00
usb.c tests: Remove unnecessary glib.h includes 2016-06-07 18:19:24 +03:00
usb.h tests: usb: Generic usb device hotplug 2014-10-15 05:03:13 +02:00
virtio-mmio.c libqos: add qvirtqueue_cleanup() 2016-06-20 11:44:12 +01:00
virtio-mmio.h libqos: Add virtio MMIO support 2015-03-10 14:02:20 +01:00
virtio-pci.c qtest: ask endianness of the target in qtest_init() 2016-10-14 10:06:47 +11:00
virtio-pci.h libqos: drop duplicated virtio_pci.h definitions 2016-06-20 11:44:12 +01:00
virtio.c libqos: fix qvring_init() 2016-09-28 11:21:46 +01:00
virtio.h libqos: add qvirtqueue_cleanup() 2016-06-20 11:44:12 +01:00