]> git.proxmox.com Git - mirror_qemu.git/commitdiff
hw/audio/lm4549: Add errp error reporting to init function
authorMartin Kletzander <mkletzan@redhat.com>
Mon, 25 Apr 2022 08:21:47 +0000 (10:21 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 22 Sep 2023 14:30:07 +0000 (16:30 +0200)
This will be used in future commit.

Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <be1bf295b3c6a3dee272b4b4e8115e37c2a772b5.1650874791.git.mkletzan@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
hw/audio/lm4549.c
hw/audio/lm4549.h
hw/audio/pl041.c

index 32b1481b5614ca637c0300f20db9aa1779f434b7..418041bc9c6c43fbb0ddfcce0c8d754b4b5a8480 100644 (file)
@@ -276,7 +276,8 @@ static int lm4549_post_load(void *opaque, int version_id)
     return 0;
 }
 
-void lm4549_init(lm4549_state *s, lm4549_callback data_req_cb, void* opaque)
+void lm4549_init(lm4549_state *s, lm4549_callback data_req_cb, void* opaque,
+                 Error **errp)
 {
     struct audsettings as;
 
index aba9bb5b077c48895ea344dfe8496df94987b603..61c3ab12dd338379c94d403b5c0286d9c5b6aefd 100644 (file)
@@ -36,7 +36,8 @@ typedef struct {
 extern const VMStateDescription vmstate_lm4549_state;
 
 
-void lm4549_init(lm4549_state *s, lm4549_callback data_req, void *opaque);
+void lm4549_init(lm4549_state *s, lm4549_callback data_req, void *opaque,
+                 Error **errp);
 uint32_t lm4549_read(lm4549_state *s, hwaddr offset);
 void lm4549_write(lm4549_state *s, hwaddr offset, uint32_t value);
 uint32_t lm4549_write_samples(lm4549_state *s, uint32_t left, uint32_t right);
index 03acd4fe344b95655cc9bf752d87251b486817d8..868dffbfd321bae6ec9295e2f79eb823fb854b7f 100644 (file)
@@ -564,7 +564,7 @@ static void pl041_realize(DeviceState *dev, Error **errp)
     }
 
     /* Init the codec */
-    lm4549_init(&s->codec, &pl041_request_data, (void *)s);
+    lm4549_init(&s->codec, &pl041_request_data, (void *)s, errp);
 }
 
 static const VMStateDescription vmstate_pl041_regfile = {