aboutsummaryrefslogtreecommitdiff
path: root/hw/gus.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/gus.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/gus.c')
-rw-r--r--hw/gus.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/hw/gus.c b/hw/gus.c
index 070aa99a3b..44f3e253a9 100644
--- a/hw/gus.c
+++ b/hw/gus.c
@@ -250,16 +250,12 @@ static int GUS_load (QEMUFile *f, void *opaque, int version_id)
return 0;
}
-int GUS_init (AudioState *audio, qemu_irq *pic)
+int GUS_init (qemu_irq *pic)
{
+ AudioState *audio = AUD_init();
GUSState *s;
struct audsettings as;
- if (!audio) {
- dolog ("No audio state\n");
- return -1;
- }
-
s = qemu_mallocz (sizeof (*s));
AUD_register_card (audio, "gus", &s->card);