]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
audio/noaudio: convert to QOM lifecycle methods
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Fri, 16 Jan 2026 07:49:05 +0000 (11:49 +0400)
committerMarc-André Lureau <marcandre.lureau@redhat.com>
Mon, 23 Feb 2026 13:38:22 +0000 (14:38 +0100)
Remove the legacy driver init/fini callbacks from the null audio backend.

Both no_audio_init() and no_audio_fini() were no-ops that performed
no real initialization or cleanup work.

Reviewed-by: Mark Cave-Ayland <mark.caveayland@nutanix.com>
Reviewed-by: Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
audio/noaudio.c

index 65679b8b13da7667f2d0ecf57764dcb46ab60d76..2bd110caac4959eee942eceef19575619d744dd0 100644 (file)
@@ -119,16 +119,6 @@ static void no_enable_in(HWVoiceIn *hw, bool enable)
     }
 }
 
-static void *no_audio_init(Audiodev *dev, Error **errp)
-{
-    return &no_audio_init;
-}
-
-static void no_audio_fini (void *opaque)
-{
-    (void) opaque;
-}
-
 static struct audio_pcm_ops no_pcm_ops = {
     .init_out = no_init_out,
     .fini_out = no_fini_out,
@@ -146,8 +136,6 @@ static struct audio_pcm_ops no_pcm_ops = {
 
 static struct audio_driver no_audio_driver = {
     .name           = "none",
-    .init           = no_audio_init,
-    .fini           = no_audio_fini,
     .pcm_ops        = &no_pcm_ops,
     .max_voices_out = INT_MAX,
     .max_voices_in  = INT_MAX,