diff options
| author | Greg Kurz <groug@kaod.org> | 2020-01-06 15:56:37 +0100 |
|---|---|---|
| committer | David Gibson <david@gibson.dropbear.id.au> | 2020-01-08 11:01:59 +1100 |
| commit | d1214b819f26dcf95329af624e74bf42eeeb1a9a (patch) | |
| tree | 38e7e8832da82cb6ba565644d598f4ff975eb5a2 /hw/ppc/spapr_irq.c | |
| parent | 0da41d3c5af7897e742c2fa4f6a5c5609b86c493 (diff) | |
| download | focaccia-qemu-d1214b819f26dcf95329af624e74bf42eeeb1a9a.tar.gz focaccia-qemu-d1214b819f26dcf95329af624e74bf42eeeb1a9a.zip | |
spapr, pnv, xive: Add a "xive-fabric" link to the XIVE router
In order to get rid of qdev_get_machine(), first add a pointer to the XIVE fabric under the XIVE router and make it configurable through a QOM link property. Configure it in the spapr and pnv machine. In the case of pnv, the XIVE routers are under the chip, so this is done with a QOM alias property of the POWER9 pnv chip. Signed-off-by: Greg Kurz <groug@kaod.org> Signed-off-by: Cédric Le Goater <clg@kaod.org> Message-Id: <20200106145645.4539-5-clg@kaod.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/ppc/spapr_irq.c')
| -rw-r--r-- | hw/ppc/spapr_irq.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/ppc/spapr_irq.c b/hw/ppc/spapr_irq.c index 373505d28b..1f630f296b 100644 --- a/hw/ppc/spapr_irq.c +++ b/hw/ppc/spapr_irq.c @@ -332,6 +332,8 @@ void spapr_irq_init(SpaprMachineState *spapr, Error **errp) * priority */ qdev_prop_set_uint32(dev, "nr-ends", nr_servers << 3); + object_property_set_link(OBJECT(dev), OBJECT(spapr), "xive-fabric", + &error_abort); qdev_init_nofail(dev); spapr->xive = SPAPR_XIVE(dev); |