diff options
author | Greg Kurz <groug@kaod.org> | 2020-01-06 15:56:36 +0100 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2020-01-08 11:01:59 +1100 |
commit | 0da41d3c5af7897e742c2fa4f6a5c5609b86c493 (patch) | |
tree | 22d98f3916e9eb18bffc554e02b4dd1e52efa9f6 /include | |
parent | 245cdb7f547db0a99fb5f4847f929a508cf82351 (diff) |
pnv/xive: Use device_class_set_parent_realize()
The XIVE router base class currently inherits an empty realize hook
from the sysbus device base class, but it will soon implement one
of its own to perform some sanity checks. Do the preliminary plumbing
to have it called.
Signed-off-by: Greg Kurz <groug@kaod.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Message-Id: <20200106145645.4539-4-clg@kaod.org>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'include')
-rw-r--r-- | include/hw/ppc/pnv_xive.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/include/hw/ppc/pnv_xive.h b/include/hw/ppc/pnv_xive.h index f4c7caad40..76cf16f644 100644 --- a/include/hw/ppc/pnv_xive.h +++ b/include/hw/ppc/pnv_xive.h @@ -16,6 +16,10 @@ struct PnvChip; #define TYPE_PNV_XIVE "pnv-xive" #define PNV_XIVE(obj) OBJECT_CHECK(PnvXive, (obj), TYPE_PNV_XIVE) +#define PNV_XIVE_CLASS(klass) \ + OBJECT_CLASS_CHECK(PnvXiveClass, (klass), TYPE_PNV_XIVE) +#define PNV_XIVE_GET_CLASS(obj) \ + OBJECT_GET_CLASS(PnvXiveClass, (obj), TYPE_PNV_XIVE) #define XIVE_BLOCK_MAX 16 @@ -85,6 +89,12 @@ typedef struct PnvXive { uint64_t edt[XIVE_TABLE_EDT_MAX]; } PnvXive; +typedef struct PnvXiveClass { + XiveRouterClass parent_class; + + DeviceRealize parent_realize; +} PnvXiveClass; + void pnv_xive_pic_print_info(PnvXive *xive, Monitor *mon); #endif /* PPC_PNV_XIVE_H */ |