aboutsummaryrefslogtreecommitdiff
path: root/hw/musicpal.c
diff options
context:
space:
mode:
authorPaul Brook <paul@codesourcery.com>2009-05-12 12:33:04 +0100
committerPaul Brook <paul@codesourcery.com>2009-05-12 12:33:04 +0100
commit22d83b140e7b2dda555b7e3035050454f8764b7f (patch)
treeb80cd7f2cbae7951323871218db3772dd8b3b8c7 /hw/musicpal.c
parent0d9acba8fddbf970c7353083e6a60b47017ce3e4 (diff)
Push AUD_init down to devices
Now we can safely call AUD_init multiple times we can push it down to individual audio devices, rather than having to pass it from the board init. Signed-off-by: Paul Brook <paul@codesourcery.com>
Diffstat (limited to 'hw/musicpal.c')
-rw-r--r--hw/musicpal.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/hw/musicpal.c b/hw/musicpal.c
index 0c47e5d80d..b1cece4626 100644
--- a/hw/musicpal.c
+++ b/hw/musicpal.c
@@ -422,13 +422,10 @@ static CPUWriteMemoryFunc *musicpal_audio_writefn[] = {
static i2c_interface *musicpal_audio_init(qemu_irq irq)
{
- AudioState *audio;
musicpal_audio_state *s;
i2c_interface *i2c;
int iomemtype;
- audio = AUD_init();
-
s = qemu_mallocz(sizeof(musicpal_audio_state));
s->irq = irq;
@@ -436,7 +433,7 @@ static i2c_interface *musicpal_audio_init(qemu_irq irq)
i2c->bus = i2c_init_bus();
i2c->current_addr = -1;
- s->wm = wm8750_init(i2c->bus, audio);
+ s->wm = wm8750_init(i2c->bus);
if (!s->wm)
return NULL;
i2c_set_slave_address(s->wm, MP_WM_ADDR);