qemu-e2k/hw/ppc
Frederic Barrat ddf0676f1a pnv_phb4_pec: Simplify/align code to parent user-created PHBs
When instantiating a user-created PHB on P9/P10, we don't really have
a reason any more to go through an indirection in pnv_chip_add_phb()
in pnv.c, we can go straight to the right function in
pnv_phb4_pec.c. That way, default PHBs and user-created PHBs are all
handled in the same file.  This patch also renames pnv_phb4_get_pec()
to pnv_pec_add_phb() to better reflect that it "hooks" a PHB to a PEC.

For P8, the PHBs are parented to the chip directly, so it makes sense
to keep calling pnv_chip_add_phb() in pnv.c, to also be consistent
with where default PHBs are handled. The only change here is that,
since that function is now only used for P8, we can refine the return
type.

So overall, the PnvPHB front-end now has a pnv_phb_user_get_parent()
function which handles the parenting of the user-created PHBs by
calling the right function in the right file based on the processor
version. It's also easily extensible if we ever need to support a
different parent object.

Signed-off-by: Frederic Barrat <fbarrat@linux.ibm.com>
Message-Id: <20230302163715.129635-5-fbarrat@linux.ibm.com>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
2023-03-03 16:50:17 -03:00
..
e500-ccsr.h
e500.c hw/ppc/e500.c: Attach eSDHC unimplemented region to ccsr_addr_space 2023-02-05 06:40:28 -03:00
e500.h hw/ppc/e500: Add Freescale eSDHC to e500plat 2022-12-21 14:17:55 -03:00
e500plat.c hw/ppc/e500{, plat}: Drop redundant checks for presence of platform bus 2023-02-05 06:40:28 -03:00
fdt.c
fw_cfg.c
Kconfig hw/ppc/Kconfig: Remove unused dependencies from PEGASOS2 2023-01-08 01:54:22 -05:00
mac_newworld.c mac_{old,new}world: Use local variable instead of qdev_get_machine() 2023-02-06 11:41:39 +00:00
mac_oldworld.c mac_oldworld: Allow specifying nvram backing store 2023-02-06 11:41:39 +00:00
meson.build ppc440_uc.c: Move DDR2 SDRAM controller model to ppc4xx_sdram.c 2022-10-28 13:15:22 -03:00
mpc8544_guts.c
mpc8544ds.c hw/ppc/e500: Remove if statement which is now always true 2022-10-17 16:15:09 -03:00
pef.c
pegasos2.c Do not include hw/hw.h if it is not necessary 2023-02-27 09:15:38 +01:00
pnv_bmc.c
pnv_core.c include/hw/ppc: Split pnv_chip.h off pnv.h 2023-01-20 07:25:10 +01:00
pnv_homer.c include/hw/ppc: Split pnv_chip.h off pnv.h 2023-01-20 07:25:10 +01:00
pnv_lpc.c hw/isa: Rename isa_bus_irqs() -> isa_bus_register_input_irqs() 2023-02-27 22:29:02 +01:00
pnv_occ.c
pnv_pnor.c
pnv_psi.c include/hw/ppc: Don't include hw/pci-host/pnv_phb.h from pnv.h 2023-01-20 07:25:18 +01:00
pnv_sbe.c
pnv_xscom.c include/hw/ppc: Split pnv_chip.h off pnv.h 2023-01-20 07:25:10 +01:00
pnv.c pnv_phb4_pec: Simplify/align code to parent user-created PHBs 2023-03-03 16:50:17 -03:00
ppc4xx_devs.c ppc4xx_sdram: Move ppc4xx_sdram_banks() to ppc4xx_sdram.c 2022-10-28 13:15:23 -03:00
ppc4xx_pci.c include/hw/pci: Split pci_device.h off pci.h 2023-01-08 01:54:22 -05:00
ppc4xx_sdram.c bulk: Rename TARGET_FMT_plx -> HWADDR_FMT_plx 2023-01-18 11:14:34 +01:00
ppc405_boards.c ppc4xx_sdram: Rename functions to prevent name clashes 2022-10-17 16:15:09 -03:00
ppc405_uc.c Drop duplicate #include 2023-02-08 07:28:05 +01:00
ppc405.h ppc4xx_sdram: QOM'ify 2022-10-17 16:15:09 -03:00
ppc440_bamboo.c Drop duplicate #include 2023-02-08 07:28:05 +01:00
ppc440_pcix.c include/hw/pci: Split pci_device.h off pci.h 2023-01-08 01:54:22 -05:00
ppc440_uc.c ppc440_uc.c: Move DDR2 SDRAM controller model to ppc4xx_sdram.c 2022-10-28 13:15:22 -03:00
ppc440.h ppc440_sdram: QOM'ify 2022-10-17 16:15:09 -03:00
ppc_booke.c
ppc.c hw/ppc: Use QEMU_IOTHREAD_LOCK_GUARD in ppc_set_irq 2023-01-04 16:20:01 -08:00
ppce500_spin.c
prep_systemio.c
prep.c hw/rtc: Rename rtc_[get|set]_memory -> mc146818rtc_[get|set]_cmos_data 2023-02-27 22:29:02 +01:00
rs6000_mc.c
sam460ex.c hw/ppc/sam460ex: Correctly set MAL properties 2023-02-27 22:29:02 +01:00
spapr_caps.c
spapr_cpu_core.c
spapr_drc.c Drop duplicate #include 2023-02-08 07:28:05 +01:00
spapr_events.c
spapr_hcall.c target/ppc: introduce ppc_maybe_interrupt 2022-10-28 13:15:22 -03:00
spapr_iommu.c
spapr_irq.c
spapr_numa.c
spapr_nvdimm.c
spapr_ovec.c
spapr_pci_nvlink2.c hw/ppc/pnv: Avoid dynamic stack allocation 2022-09-22 16:38:28 +01:00
spapr_pci_vfio.c include/hw/pci: Split pci_device.h off pci.h 2023-01-08 01:54:22 -05:00
spapr_pci.c pci: drop redundant PCIDeviceClass::is_bridge field 2022-12-21 07:32:24 -05:00
spapr_rng.c
spapr_rtas_ddw.c
spapr_rtas.c target/ppc: introduce ppc_maybe_interrupt 2022-10-28 13:15:22 -03:00
spapr_rtc.c
spapr_softmmu.c
spapr_tpm_proxy.c
spapr_vio.c
spapr_vof.c
spapr.c ppc patch queue for 2022-12-21: 2022-12-21 18:08:09 +00:00
trace-events ppc4xx_sdram: Generalise bank setup 2022-10-28 13:15:23 -03:00
trace.h
virtex_ml507.c hw/ppc/virtex_ml507: Prefer local over global variable 2022-12-21 14:17:55 -03:00
vof.c