[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 07/12] hw/audio/lm4549: Add errp error reporting to init function
From: |
Paolo Bonzini |
Subject: |
[PULL 07/12] hw/audio/lm4549: Add errp error reporting to init function |
Date: |
Fri, 22 Sep 2023 11:31:20 +0200 |
From: Martin Kletzander <mkletzan@redhat.com>
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 | 3 ++-
hw/audio/lm4549.h | 3 ++-
hw/audio/pl041.c | 2 +-
3 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/hw/audio/lm4549.c b/hw/audio/lm4549.c
index 32b1481b561..418041bc9c6 100644
--- a/hw/audio/lm4549.c
+++ b/hw/audio/lm4549.c
@@ -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;
diff --git a/hw/audio/lm4549.h b/hw/audio/lm4549.h
index aba9bb5b077..61c3ab12dd3 100644
--- a/hw/audio/lm4549.h
+++ b/hw/audio/lm4549.h
@@ -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);
diff --git a/hw/audio/pl041.c b/hw/audio/pl041.c
index 03acd4fe344..868dffbfd32 100644
--- a/hw/audio/pl041.c
+++ b/hw/audio/pl041.c
@@ -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 = {
--
2.41.0
- [PULL 00/12] Audio, i386 patches for 2022-09-22, Paolo Bonzini, 2023/09/22
- [PULL 02/12] target/i386: Export GDS_NO bit to guests, Paolo Bonzini, 2023/09/22
- [PULL 01/12] target/i386: enumerate bit 56 of MSR_IA32_VMX_BASIC, Paolo Bonzini, 2023/09/22
- [PULL 03/12] qemu/timer: Add host ticks function for RISC-V, Paolo Bonzini, 2023/09/22
- [PULL 04/12] audio: remove QEMU_AUDIO_* and -audio-help support, Paolo Bonzini, 2023/09/22
- [PULL 06/12] hw/audio: Simplify hda audio init, Paolo Bonzini, 2023/09/22
- [PULL 11/12] ui/vnc: Require audiodev= to enable audio, Paolo Bonzini, 2023/09/22
- [PULL 10/12] audio/spiceaudio: Fail initialisation when not using spice, Paolo Bonzini, 2023/09/22
- [PULL 07/12] hw/audio/lm4549: Add errp error reporting to init function,
Paolo Bonzini <=
- [PULL 05/12] hw/input/tsc210x: Extract common init code into new function, Paolo Bonzini, 2023/09/22
- [PULL 08/12] hw/display/xlnx_dp.c: Add audiodev property, Paolo Bonzini, 2023/09/22
- [PULL 09/12] tests/qtest: Specify audiodev= and -audiodev, Paolo Bonzini, 2023/09/22
- [PULL 12/12] audio: Require AudioState in AUD_add_capture, Paolo Bonzini, 2023/09/22