aboutsummaryrefslogtreecommitdiff
path: root/hw/tosa.c
diff options
context:
space:
mode:
authorAnthony Liguori <aliguori@us.ibm.com>2011-12-16 13:36:39 -0600
committerAnthony Liguori <aliguori@us.ibm.com>2012-01-27 10:50:47 -0600
commitcd6c4cf28b529aaee0367256d37f349e3b125818 (patch)
treea13e1eee93c85362ef4ce4c33cc3608412c64f7a /hw/tosa.c
parentba7c05205c4ba2fd08096b0083fc1e5decf3c342 (diff)
downloadqemu-cd6c4cf28b529aaee0367256d37f349e3b125818.zip
qemu-cd6c4cf28b529aaee0367256d37f349e3b125818.tar.gz
qemu-cd6c4cf28b529aaee0367256d37f349e3b125818.tar.bz2
ssi: convert to QEMU Object Model
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/tosa.c')
-rw-r--r--hw/tosa.c19
1 files changed, 13 insertions, 6 deletions
diff --git a/hw/tosa.c b/hw/tosa.c
index 0caba79..ade4cf6 100644
--- a/hw/tosa.c
+++ b/hw/tosa.c
@@ -266,13 +266,20 @@ static I2CSlaveInfo tosa_dac_info = {
.event = tosa_dac_event,
.recv = tosa_dac_recv,
.send = tosa_dac_send
-};
+ };
+
+static void tosa_ssp_class_init(ObjectClass *klass, void *data)
+{
+ SSISlaveClass *k = SSI_SLAVE_CLASS(klass);
+
+ k->init = tosa_ssp_init;
+ k->transfer = tosa_ssp_tansfer;
+}
-static SSISlaveInfo tosa_ssp_info = {
- .qdev.name = "tosa-ssp",
- .qdev.size = sizeof(SSISlave),
- .init = tosa_ssp_init,
- .transfer = tosa_ssp_tansfer
+static DeviceInfo tosa_ssp_info = {
+ .name = "tosa-ssp",
+ .size = sizeof(SSISlave),
+ .class_init = tosa_ssp_class_init,
};
static void tosa_register_devices(void)