qemu/hw
David Gibson b0e5196a52 pci: Simplify pci_bus_is_root()
pci_bus_is_root() currently relies on a method in the PCIBusClass.
But it's always known if a PCI bus is a root bus when we create it, so
using a dynamic method is overkill.

This replaces it with an IS_ROOT bit in a new flags field, which is set on
root buses and otherwise clear.  As a bonus this removes the special
is_root logic from pci_expander_bridge, since it already creates its bus
as a root bus.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Marcel Apfelbaum <marcel@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Greg Kurz <groug@kaod.org>
Message-Id: <20190424041959.4087-3-david@gibson.dropbear.id.au>
2019-05-20 18:40:02 -04:00
..
9pfs trace-events: Fix attribution of trace points to source 2019-03-22 16:18:07 +00:00
acpi acpi/pcihp: Add a few more trace points related to unplug 2019-05-20 18:40:02 -04:00
adc kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
alpha * Kconfig improvements (msi_nonbroken, imply for default PCI devices) 2019-03-28 09:18:53 +00:00
arm hw/arm/virt-acpi-build: pass AcpiMcfgInfo to build_mcfg() 2019-05-20 18:40:02 -04:00
audio Revert "audio: fix pc speaker init" 2019-04-01 08:53:40 +02:00
block vhost-user-blk: Add support to reconnect backend 2019-05-20 18:40:02 -04:00
bt kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
char Mostly bugfixes and cleanups, the most important being 2019-05-17 16:17:34 +01:00
core hw: report invalid disable-legacy|modern usage for virtio-1-only devs 2019-05-20 18:40:02 -04:00
cpu kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
cris cris-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
display hw: report invalid disable-legacy|modern usage for virtio-1-only devs 2019-05-20 18:40:02 -04:00
dma hw/dma: Compile the bcm2835_dma device as common object 2019-04-29 17:36:03 +01:00
gpio Pull request 2019-03-25 17:01:10 +00:00
hppa * Kconfig improvements (msi_nonbroken, imply for default PCI devices) 2019-03-28 09:18:53 +00:00
hyperv hyperv: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
i2c hw/arm: Express dependencies of realview, versatile and vexpress with Kconfig 2019-05-13 09:36:31 +02:00
i386 hw/arm/virt-acpi-build: pass AcpiMcfgInfo to build_mcfg() 2019-05-20 18:40:02 -04:00
ide Kconfig settings for the Arm machines 2019-05-13 16:52:56 +01:00
input hw/input: Add a CONFIG_PS2 switch for the ps2.c file 2019-05-15 11:56:53 +02:00
intc Mostly bugfixes and cleanups, the most important being 2019-05-17 16:17:34 +01:00
ipack build: convert pci.mak to Kconfig 2019-03-07 21:45:53 +01:00
ipmi ipmi: express dependencies with kconfig 2019-03-07 21:45:53 +01:00
isa hw/i386/acpi: Add object_resolve_type_unambiguous to improve modularity 2019-05-17 15:19:24 +02:00
lm32 pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
m68k m68k-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
mem trace-events: Shorten file names in comments 2019-03-22 16:18:07 +00:00
microblaze pflash: Clean up after commit 368a354f02, part 2 2019-03-11 22:53:44 +01:00
mips mips-fulong2e: obey -vga none 2019-05-17 15:19:38 +02:00
misc leon3: introduce the plug and play mechanism 2019-05-17 09:17:11 +01:00
moxie moxie-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
net Mostly bugfixes and cleanups, the most important being 2019-05-17 16:17:34 +01:00
nios2 Add generic Nios II board. 2019-04-29 16:09:51 +01:00
nvram trace-events: Shorten file names in comments 2019-03-22 16:18:07 +00:00
openrisc target/openrisc: Fix LGPL information in the file headers 2019-05-08 17:45:54 +02:00
pci pci: Simplify pci_bus_is_root() 2019-05-20 18:40:02 -04:00
pci-bridge pci: Simplify pci_bus_is_root() 2019-05-20 18:40:02 -04:00
pci-host hw/pci-host: Use object_initialize_child for correct reference counting 2019-05-02 16:56:33 +02:00
pcmcia kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
ppc ppc patch queue 2019-04-26 2019-04-27 21:34:46 +01:00
rdma Clean up header guards that don't match their file name 2019-05-13 08:58:55 +02:00
riscv riscv: plic: Log guest errors 2019-04-04 16:36:21 -07:00
s390x Machine queue, 2019-04-25 2019-04-26 14:30:18 +01:00
scsi megasas: fix mapped frame size 2019-05-15 11:56:53 +02:00
sd Clean up header guards that don't match their file name 2019-05-13 08:58:55 +02:00
sh4 hw/usb/hcd-ohci: Move PCI-related code into a separate file 2019-05-02 08:42:17 +02:00
smbios kconfig: introduce kconfig files 2019-03-07 21:45:53 +01:00
sparc Mostly bugfixes and cleanups, the most important being 2019-05-17 16:17:34 +01:00
sparc64 * Kconfig improvements (msi_nonbroken, imply for default PCI devices) 2019-03-28 09:18:53 +00:00
ssi hw/ssi/xilinx_spips: Avoid variable length array 2019-04-29 17:35:57 +01:00
timer grlib, gptimer: get rid of the old-style create function 2019-05-17 09:17:11 +01:00
tpm Clean up ill-advised or unusual header guards 2019-05-13 08:58:55 +02:00
tricore - qtest fixes 2019-03-08 16:31:34 +00:00
unicore32 unicore32-softmmu.mak: express dependencies with Kconfig 2019-03-07 21:46:19 +01:00
usb hw/usb: avoid format truncation warning when formatting port name 2019-05-03 08:56:58 +02:00
vfio ppc patch queue 2019-04-26 2019-04-27 21:34:46 +01:00
virtio pci: Simplify pci_bus_is_root() 2019-05-20 18:40:02 -04:00
watchdog trace-events: Fix attribution of trace points to source 2019-03-22 16:18:07 +00:00
xen trace-events: Shorten file names in comments 2019-03-22 16:18:07 +00:00
xenpv xen: Replace few mentions of xend by libxl 2019-01-14 13:45:40 +00:00
xtensa Clean up ill-advised or unusual header guards 2019-05-13 08:58:55 +02:00
Kconfig kconfig: add dependencies on CONFIG_MSI_NONBROKEN 2019-03-18 09:39:57 +01:00
Makefile.objs i2c: express dependencies with Kconfig 2019-03-07 21:45:53 +01:00