mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 01:03:55 -06:00
xive: Link "xive" property to XiveEndSource::xrtr pointer
The END source object has both a pointer and a "xive" property pointing to the router object. Confusing bugs could arise if these ever go out of sync. Change the property definition so that it explicitely sets the pointer. The property isn't optional : not being able to set the link is a bug and QEMU should rather abort than exit in this case. Signed-off-by: Greg Kurz <groug@kaod.org> Message-Id: <157383333784.165747.5298512574054268786.stgit@bahia.lan> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
82ea3a1b29
commit
0ab2316e9e
3 changed files with 7 additions and 14 deletions
|
@ -290,8 +290,8 @@ static void spapr_xive_realize(DeviceState *dev, Error **errp)
|
|||
*/
|
||||
object_property_set_int(OBJECT(end_xsrc), xive->nr_irqs, "nr-ends",
|
||||
&error_fatal);
|
||||
object_property_add_const_link(OBJECT(end_xsrc), "xive", OBJECT(xive),
|
||||
&error_fatal);
|
||||
object_property_set_link(OBJECT(end_xsrc), OBJECT(xive), "xive",
|
||||
&error_abort);
|
||||
object_property_set_bool(OBJECT(end_xsrc), true, "realized", &local_err);
|
||||
if (local_err) {
|
||||
error_propagate(errp, local_err);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue