aboutsummaryrefslogtreecommitdiff
path: root/include/hw
diff options
context:
space:
mode:
authorGreg Kurz <groug@kaod.org>2017-06-08 15:42:50 +0200
committerDavid Gibson <david@gibson.dropbear.id.au>2017-06-09 12:12:34 +1000
commit100f738850639a108d6767316ce4dcc1d1ea4ae4 (patch)
tree93f9e62c7818d3f2437ae2b9c1d7dd28407d8aa8 /include/hw
parentad265631c0a0addc06ec3c4f133e746f4dcc872a (diff)
downloadqemu-100f738850639a108d6767316ce4dcc1d1ea4ae4.zip
qemu-100f738850639a108d6767316ce4dcc1d1ea4ae4.tar.gz
qemu-100f738850639a108d6767316ce4dcc1d1ea4ae4.tar.bz2
xics: pass appropriate types to realize() handlers.
It makes more sense to pass an IPCState * to handlers of ICPStateClass instead of a DeviceState *, if only to benefit from compile time type checking. The same goes with ICSStateClass. While here, we also change the declaration of ICPStateClass in xics.h for consistency. Signed-off-by: Greg Kurz <groug@kaod.org> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'include/hw')
-rw-r--r--include/hw/ppc/xics.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/hw/ppc/xics.h b/include/hw/ppc/xics.h
index 3114532..797df82 100644
--- a/include/hw/ppc/xics.h
+++ b/include/hw/ppc/xics.h
@@ -65,9 +65,9 @@ typedef struct XICSFabric XICSFabric;
struct ICPStateClass {
DeviceClass parent_class;
- void (*realize)(DeviceState *dev, Error **errp);
- void (*pre_save)(ICPState *s);
- int (*post_load)(ICPState *s, int version_id);
+ void (*realize)(ICPState *icp, Error **errp);
+ void (*pre_save)(ICPState *icp);
+ int (*post_load)(ICPState *icp, int version_id);
void (*cpu_setup)(ICPState *icp, PowerPCCPU *cpu);
void (*reset)(ICPState *icp);
};
@@ -113,7 +113,7 @@ struct PnvICPState {
struct ICSStateClass {
DeviceClass parent_class;
- void (*realize)(DeviceState *dev, Error **errp);
+ void (*realize)(ICSState *s, Error **errp);
void (*pre_save)(ICSState *s);
int (*post_load)(ICSState *s, int version_id);
void (*reject)(ICSState *s, uint32_t irq);