diff options
author | Daniel Henrique Barboza | 2022-08-11 18:39:43 +0200 |
---|---|---|
committer | Daniel Henrique Barboza | 2022-08-31 19:08:06 +0200 |
commit | ba47c3a4f888e99dedde1fed740927e973f9bc32 (patch) | |
tree | 5ad441aa48c290bcd73da3df74b06c73e36fdcf2 /include | |
parent | ppc/pnv: set root port chassis and slot using Bus properties (diff) | |
download | qemu-ba47c3a4f888e99dedde1fed740927e973f9bc32.tar.gz qemu-ba47c3a4f888e99dedde1fed740927e973f9bc32.tar.xz qemu-ba47c3a4f888e99dedde1fed740927e973f9bc32.zip |
ppc/pnv: add helpers for pnv-phb user devices
pnv_parent_qom_fixup() and pnv_parent_bus_fixup() are versions of the
helpers that were reverted by commit 9c10d86fee "ppc/pnv: Remove
user-created PHB{3,4,5} devices". They are needed to amend the QOM and
bus hierarchies of user created pnv-phbs, matching them with default
pnv-phbs.
A new helper pnv_phb_user_device_init() is created to handle
user-created devices setup. We're going to call it inside
pnv_phb_realize() in case we're realizing an user created device. This
will centralize all user device realated in a single spot, leaving the
realize functions of the phb3/phb4 backends untouched.
Another helper called pnv_chip_add_phb() was added to handle the
particularities of each chip version when adding a new PHB.
Signed-off-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Frederic Barrat <fbarrat@linux.ibm.com>
Message-Id: <20220811163950.578927-5-danielhb413@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/hw/ppc/pnv.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/hw/ppc/pnv.h b/include/hw/ppc/pnv.h index 290adac76c..c44f357bce 100644 --- a/include/hw/ppc/pnv.h +++ b/include/hw/ppc/pnv.h @@ -234,6 +234,7 @@ struct PnvMachineState { }; PnvChip *pnv_get_chip(PnvMachineState *pnv, uint32_t chip_id); +Object *pnv_chip_add_phb(PnvChip *chip, PnvPHB *phb, Error **errp); #define PNV_FDT_ADDR 0x01000000 #define PNV_TIMEBASE_FREQ 512000000ULL |