diff options
author | David Gibson <david@gibson.dropbear.id.au> | 2019-09-24 16:00:33 +1000 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2019-10-04 19:08:21 +1000 |
commit | 00ed3da9b5c2e66e796a172df3e19545462b9c90 (patch) | |
tree | d9d14269a3d439400a63d7d2febb6cb9f1ee1688 /include/hw | |
parent | 627fa61746f70f7c799f08e9048bb6a482402138 (diff) | |
download | qemu-00ed3da9b5c2e66e796a172df3e19545462b9c90.zip qemu-00ed3da9b5c2e66e796a172df3e19545462b9c90.tar.gz qemu-00ed3da9b5c2e66e796a172df3e19545462b9c90.tar.bz2 |
xics: Minor fixes for XICSFabric interface
Interface instances should never be directly dereferenced. So, the common
practice is to make them incomplete types to make sure no-one does that.
XICSFrabric, however, had a dummy type which is less safe.
We were also using OBJECT_CHECK() where we should have been using
INTERFACE_CHECK().
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Greg Kurz <groug@kaod.org>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Diffstat (limited to 'include/hw')
-rw-r--r-- | include/hw/ppc/xics.h | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/include/hw/ppc/xics.h b/include/hw/ppc/xics.h index 64a2c88..faa33ae 100644 --- a/include/hw/ppc/xics.h +++ b/include/hw/ppc/xics.h @@ -147,13 +147,9 @@ struct ICSIRQState { uint8_t flags; }; -struct XICSFabric { - Object parent; -}; - #define TYPE_XICS_FABRIC "xics-fabric" #define XICS_FABRIC(obj) \ - OBJECT_CHECK(XICSFabric, (obj), TYPE_XICS_FABRIC) + INTERFACE_CHECK(XICSFabric, (obj), TYPE_XICS_FABRIC) #define XICS_FABRIC_CLASS(klass) \ OBJECT_CLASS_CHECK(XICSFabricClass, (klass), TYPE_XICS_FABRIC) #define XICS_FABRIC_GET_CLASS(obj) \ |