qemu-e2k/hw
Daniel Henrique Barboza 8ec1e4f1ef ppc/pnv: add phb-id/chip-id PnvPHB3RootBus properties
We rely on the phb-id and chip-id, which are PHB properties, to assign
chassis and slot to the root port. For default devices this is no big
deal: the root port is being created under pnv_phb_realize() and the
values are being passed on via the 'index' and 'chip-id' of the
pnv_phb_attach_root_port() helper.

If we want to implement user created root ports we have a problem. The
user created root port will not be aware of which PHB it belongs to,
unless we're willing to violate QOM best practices and access the PHB
via dev->parent_bus->parent. What we can do is to access the root bus
parent bus.

Since we're already assigning the root port as QOM child of the bus, and
the bus is initiated using PHB properties, let's add phb-id and chip-id
as properties of the bus. This will allow us trivial access to them, for
both user-created and default root ports, without doing anything too
shady with QOM.

Reviewed-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Reviewed-by: Frederic Barrat <fbarrat@linux.ibm.com>
Message-Id: <20220811163950.578927-2-danielhb413@gmail.com>
2022-08-31 14:08:05 -03:00
..
9pfs
acpi
adc
alpha
arm hw/arm/virt-acpi-build: Present the GICR structure properly for GICv4 2022-08-12 11:25:18 +01:00
audio
avr
block virtio-scsi: fix race in virtio_scsi_dataplane_start() 2022-08-17 07:07:37 -04:00
char
core
cpu
cris
cxl hw/cxl: Correctly handle variable sized mailbox input payloads. 2022-08-17 13:08:11 -04:00
display xlnx_dp: drop unsupported AUXCommand in xlnx_dp_aux_set_command 2022-08-08 11:40:06 +02:00
dma
gpio
hppa
hyperv
i2c
i386 x86: disable rng seeding via setup_data 2022-08-17 07:07:37 -04:00
ide
input
intc
ipack
ipmi ipmi:smbus: Add a check around a memcpy 2022-08-01 06:40:50 -05:00
isa
loongarch hw/loongarch: remove acpi-build.c unused variable 'aml_len' 2022-08-05 10:02:07 -07:00
m68k
mem
microblaze
mips hw/mips/malta: turn off x86 specific features of PIIX4_PM 2022-08-08 23:23:11 +02:00
misc hw/misc/grlib_ahb_apb_pnp: Support 8 and 16 bit accesses 2022-08-08 23:43:11 +02:00
net hw/net/rocker: Avoid undefined shifts with more than 31 ports 2022-08-09 17:02:18 +08:00
nios2
nubus
nvme hw/nvme: do not enable ioeventfd by default 2022-08-01 12:01:21 +02:00
nvram
openrisc
pci
pci-bridge
pci-host ppc/pnv: add phb-id/chip-id PnvPHB3RootBus properties 2022-08-31 14:08:05 -03:00
pcmcia
ppc ppc/pnv: move attach_root_port helper to pnv-phb.c 2022-08-31 14:08:05 -03:00
rdma
remote
riscv
rtc
rx
s390x
scsi scsi-generic: Fix emulated block limits VPD page 2022-08-23 16:01:13 +02:00
sd
sensor
sh4
smbios
sparc
sparc64
ssi
timer
tpm
tricore
usb hw/usb/hcd-xhci: Fix unbounded loop in xhci_ring_chain_length() (CVE-2020-14394) 2022-08-16 11:37:19 +02:00
vfio
virtio virtio-pci: don't touch pci on virtio reset 2022-08-17 13:08:11 -04:00
watchdog
xen
xenpv
xtensa
Kconfig
meson.build