summaryrefslogtreecommitdiffstats
path: root/hw/mips_malta.c
diff options
context:
space:
mode:
authorPaul Brook2009-05-14 23:35:08 +0200
committerPaul Brook2009-05-14 23:35:08 +0200
commit1ea96673c611cdc05ea32ac81f40d9f864e18507 (patch)
tree16a99607ac0c2aab3c3ea225eebe85beed8c96d0 /hw/mips_malta.c
parentTOSC DAC i2c qdev voncersion (diff)
downloadqemu-1ea96673c611cdc05ea32ac81f40d9f864e18507.tar.gz
qemu-1ea96673c611cdc05ea32ac81f40d9f864e18507.tar.xz
qemu-1ea96673c611cdc05ea32ac81f40d9f864e18507.zip
SMBus qdev conversion
Signed-off-by: Paul Brook <paul@codesourcery.com>
Diffstat (limited to 'hw/mips_malta.c')
-rw-r--r--hw/mips_malta.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hw/mips_malta.c b/hw/mips_malta.c
index 9710adc24e..747143d3d2 100644
--- a/hw/mips_malta.c
+++ b/hw/mips_malta.c
@@ -911,7 +911,11 @@ void mips_malta_init (ram_addr_t ram_size,
eeprom_buf = qemu_mallocz(8 * 256); /* XXX: make this persistent */
for (i = 0; i < 8; i++) {
/* TODO: Populate SPD eeprom data. */
- smbus_eeprom_device_init(smbus, 0x50 + i, eeprom_buf + (i * 256));
+ DeviceState *eeprom;
+ eeprom = qdev_create(smbus, "smbus-eeprom");
+ qdev_set_prop_int(eeprom, "address", 0x50 + i);
+ qdev_set_prop_ptr(eeprom, "data", eeprom_buf + (i * 256));
+ qdev_init(eeprom);
}
pit = pit_init(0x40, i8259[0]);
DMA_init(0);