[PATCH 00/85] audio: cleanups & add a manual test

Marc-André Lureau posted 85 patches 1 month, 3 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260216-audio-v1-0-e676662e4514@redhat.com
Maintainers: Gerd Hoffmann <kraxel@redhat.com>, Christian Schoenebeck <qemu_oss@crudebyte.com>, "Marc-André Lureau" <marcandre.lureau@redhat.com>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>, Thomas Huth <huth@tuxfamily.org>, Alexandre Ratchov <alex@caoua.org>, Laurent Vivier <laurent@vivier.eu>, Manos Pitsidianakis <manos.pitsidianakis@linaro.org>, "Michael S. Tsirkin" <mst@redhat.com>, Alistair Francis <alistair@alistair23.me>, "Edgar E. Iglesias" <edgar.iglesias@gmail.com>, Peter Maydell <peter.maydell@linaro.org>, Paolo Bonzini <pbonzini@redhat.com>, "Alex Bennée" <alex.bennee@linaro.org>, "Daniel P. Berrangé" <berrange@redhat.com>, Eduardo Habkost <eduardo@habkost.net>, John Snow <jsnow@redhat.com>, Cleber Rosa <crosa@redhat.com>
MAINTAINERS                                        |    1 +
meson.build                                        |   27 +-
audio/audio_int.h                                  |  168 +-
audio/audio_template.h                             |  212 +-
audio/dsound_template.h                            |   89 +-
include/qemu/audio-capture.h                       |   28 +-
include/qemu/audio.h                               |  183 +-
include/qemu/module.h                              |    3 +-
include/qemu/timer.h                               |    1 +
include/system/replay.h                            |   11 +-
replay/replay-internal.h                           |    2 +
audio/alsaaudio.c                                  |  273 ++-
audio/audio-be.c                                   |  274 +++
audio/audio-mixeng-be.c                            | 1770 +++++++++++++++
audio/audio.c                                      | 2246 ++------------------
audio/audio_win_int.c                              |   31 +-
audio/dbusaudio.c                                  |  168 +-
audio/dsoundaudio.c                                |  265 ++-
audio/jackaudio.c                                  |  127 +-
audio/mixeng.c                                     |    1 -
audio/noaudio.c                                    |   78 +-
audio/ossaudio.c                                   |  300 ++-
audio/paaudio.c                                    |  261 +--
audio/pwaudio.c                                    |  214 +-
audio/sdlaudio.c                                   |  176 +-
audio/sndioaudio.c                                 |  108 +-
audio/spiceaudio.c                                 |  113 +-
audio/wavaudio.c                                   |  101 +-
audio/wavcapture.c                                 |    9 +-
hw/audio/ac97.c                                    |   44 +-
hw/audio/adlib.c                                   |   33 +-
hw/audio/asc.c                                     |   22 +-
hw/audio/cs4231a.c                                 |   24 +-
hw/audio/es1370.c                                  |   28 +-
hw/audio/gus.c                                     |   13 +-
hw/audio/hda-codec.c                               |   36 +-
hw/audio/lm4549.c                                  |   26 +-
hw/audio/pcspk.c                                   |    8 +-
hw/audio/sb16.c                                    |   30 +-
hw/audio/via-ac97.c                                |   22 +-
hw/audio/virtio-snd.c                              |   38 +-
hw/audio/wm8750.c                                  |   47 +-
hw/display/xlnx_dp.c                               |   18 +-
hw/usb/dev-audio.c                                 |   20 +-
replay/replay-audio.c                              |   51 +-
replay/replay.c                                    |    2 +-
replay/stubs-system.c                              |    8 +-
system/vl.c                                        |    2 -
tests/audio/audio-stubs.c                          |   69 +
tests/audio/test-audio.c                           |  619 ++++++
ui/dbus.c                                          |   20 +-
ui/vnc.c                                           |    6 +-
util/module.c                                      |    3 +
audio/coreaudio.m                                  |  201 +-
audio/meson.build                                  |   12 +-
audio/trace-events                                 |   46 +
qemu-options.hx                                    |   35 +-
.../codeconverter/codeconverter/test_regexps.py    |    1 -
scripts/modinfo-generate.py                        |  146 +-
tests/audio/meson.build                            |   23 +
tests/meson.build                                  |    1 +
ui/meson.build                                     |    3 +
62 files changed, 4983 insertions(+), 3914 deletions(-)
[PATCH 00/85] audio: cleanups & add a manual test
Posted by Marc-André Lureau 1 month, 3 weeks ago
Hi

This is the combination of the two earlier series:
[PATCH 00/37] audio: cleanups & add a manual test
[PATCH 00/43] audio: more cleanups (2/2 for 11.0)

Patches missing r-b trailers:
- scripts/modinfo: use argparse
- scripts/modinfo: make --devices optional
- scripts/modinfo: add --skip-missing-deps
- util: add some extra stubs for qemu modules initialization
- tests: start manual audio backend test
- audio: use DEFINE_TYPES
- audio: replace type_init() with DEFINE_TYPES
- audio: keep a strong reference on the backend
- replay: remove dependency on audio/
- audio: fix leak of audio capture name

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
Marc-André Lureau (85):
      audio: remove obsolete/obscure functions
      adlib: remove dead code
      audio/adlib: drop ts_helper HWVoice field
      audio/dbus: make "dbus" the default backend when using -display dbus
      qemu-options.hx: clarify default audio backend selection
      qemu-options.hx: document -audiodev dbus
      audio: replace vm_running with runstate_is_running()
      audio: list backends as modules
      build-sys: create a libaudio
      scripts/modinfo: add type annotations
      scripts/modinfo: remove trailing ;
      scripts/modinfo: use in instead of find()
      scripts/modinfo: use f-strings
      scripts/modinfo: use argparse
      scripts/modinfo: make --devices optional
      scripts/modinfo: add --skip-missing-deps
      util: add some extra stubs for qemu modules initialization
      tests: start manual audio backend test
      audio: constify audsettings argument
      audio: introduce AudioMixengBackend
      audio: use DEFINE_TYPES
      audio: simplify audio_init()
      audio: move object creation to audio_driver_init()
      audio: add QOM module-objects for each backend
      audio: remove set_dbus_server from audio_driver
      audio: lookup "audio-" object types, and realize them
      audio: drop audio driver registration
      module: remove audio module support
      audio: replace type_init() with DEFINE_TYPES
      audio: keep a strong reference on the backend
      audio: make list type declaration private
      audio: make create_pdos() private
      replay: remove dependency on audio/
      audio: make all the backend-specific APIs take the be
      audio: make AudioBackend truly abstract
      audio: split AudioBackend
      audio: AUD_ -> audio_be_
      audio-be: add common pre-conditions
      audio-be: add some state trace for debugging
      audio: split AudioMixengBackend code in audio-mixeng-be.c
      audio: make audio_driver init() & fini() optional
      audio/dbus: convert to QOM lifecycle methods
      audio/spice: convert to QOM lifecycle methods
      audio/wav: convert to QOM lifecycle methods
      audio/noaudio: convert to QOM lifecycle methods
      audio/alsa: convert to QOM lifecycle methods
      audio/oss: convert to QOM lifecycle methods
      audio/pa: convert to QOM lifecycle methods
      audio/sdl: convert to QOM lifecycle methods
      audio/pw: convert to QOM lifecycle methods
      audio/jack: convert to QOM lifecycle methods
      audio/sndio: convert to QOM lifecycle methods
      audio/coreaudio: convert to QOM lifecycle methods
      audio/dsound: convert to QOM lifecycle methods
      audio: remove audio_driver init/fini/next
      audio: remove audio_driver
      audio: move pcm_ops into AudioMixengBackendClass
      audio: constify some add_capture() arguments
      audio/alsa: replace custom logging with error_report and trace events
      audio/coreaudio: replace custom logging with error_report
      audio/dbus: remove unused AUDIO_CAP macro
      audio/dsound: replace custom logging with error_report & trace
      audio/jack: replace custom logging with report & trace
      audio/noaudio: remove unused AUDIO_CAP macro
      audio/oss: replace custom logging with report & trace
      audio/pa: replace custom logging with report & trace
      audio/pw: replace custom logging with error_report
      audio/sdl: replace custom logging with error_report
      audio/sndio: replace custom logging with error_report
      audio/spice: remove unused AUDIO_CAP macro
      audio/wav: replace custom logging with error_report
      audio/mixeng: replace redundant pcm_info fields with AudioFormat
      audio: replace int endianness with bool big_endian in audsettings
      audio: replace ldebug with trace events
      audio: rework DEBUG_POLL
      audio: replace DEBUG_CAPTURE with traces
      audio: replace DEBUG_OUT with traces
      audio: replace DEBUG_AUDIO with trace
      tests/audio: add an invalid settings test
      audio: rework invalid audsettings error
      audio: rework audio_bug()
      audio: replace remaining dolog() and AUD_log
      audio: remove AUD_log/ldebug
      audio: remove AudioMixengBackendClass.name
      audio: fix leak of audio capture name

 MAINTAINERS                                        |    1 +
 meson.build                                        |   27 +-
 audio/audio_int.h                                  |  168 +-
 audio/audio_template.h                             |  212 +-
 audio/dsound_template.h                            |   89 +-
 include/qemu/audio-capture.h                       |   28 +-
 include/qemu/audio.h                               |  183 +-
 include/qemu/module.h                              |    3 +-
 include/qemu/timer.h                               |    1 +
 include/system/replay.h                            |   11 +-
 replay/replay-internal.h                           |    2 +
 audio/alsaaudio.c                                  |  273 ++-
 audio/audio-be.c                                   |  274 +++
 audio/audio-mixeng-be.c                            | 1770 +++++++++++++++
 audio/audio.c                                      | 2246 ++------------------
 audio/audio_win_int.c                              |   31 +-
 audio/dbusaudio.c                                  |  168 +-
 audio/dsoundaudio.c                                |  265 ++-
 audio/jackaudio.c                                  |  127 +-
 audio/mixeng.c                                     |    1 -
 audio/noaudio.c                                    |   78 +-
 audio/ossaudio.c                                   |  300 ++-
 audio/paaudio.c                                    |  261 +--
 audio/pwaudio.c                                    |  214 +-
 audio/sdlaudio.c                                   |  176 +-
 audio/sndioaudio.c                                 |  108 +-
 audio/spiceaudio.c                                 |  113 +-
 audio/wavaudio.c                                   |  101 +-
 audio/wavcapture.c                                 |    9 +-
 hw/audio/ac97.c                                    |   44 +-
 hw/audio/adlib.c                                   |   33 +-
 hw/audio/asc.c                                     |   22 +-
 hw/audio/cs4231a.c                                 |   24 +-
 hw/audio/es1370.c                                  |   28 +-
 hw/audio/gus.c                                     |   13 +-
 hw/audio/hda-codec.c                               |   36 +-
 hw/audio/lm4549.c                                  |   26 +-
 hw/audio/pcspk.c                                   |    8 +-
 hw/audio/sb16.c                                    |   30 +-
 hw/audio/via-ac97.c                                |   22 +-
 hw/audio/virtio-snd.c                              |   38 +-
 hw/audio/wm8750.c                                  |   47 +-
 hw/display/xlnx_dp.c                               |   18 +-
 hw/usb/dev-audio.c                                 |   20 +-
 replay/replay-audio.c                              |   51 +-
 replay/replay.c                                    |    2 +-
 replay/stubs-system.c                              |    8 +-
 system/vl.c                                        |    2 -
 tests/audio/audio-stubs.c                          |   69 +
 tests/audio/test-audio.c                           |  619 ++++++
 ui/dbus.c                                          |   20 +-
 ui/vnc.c                                           |    6 +-
 util/module.c                                      |    3 +
 audio/coreaudio.m                                  |  201 +-
 audio/meson.build                                  |   12 +-
 audio/trace-events                                 |   46 +
 qemu-options.hx                                    |   35 +-
 .../codeconverter/codeconverter/test_regexps.py    |    1 -
 scripts/modinfo-generate.py                        |  146 +-
 tests/audio/meson.build                            |   23 +
 tests/meson.build                                  |    1 +
 ui/meson.build                                     |    3 +
 62 files changed, 4983 insertions(+), 3914 deletions(-)
---
base-commit: ece408818d27f745ef1b05fb3cc99a1e7a5bf580
change-id: 20260216-audio-89652d2709f1

Best regards,
-- 
Marc-André Lureau <marcandre.lureau@redhat.com>


Re: [PATCH 00/85] audio: cleanups & add a manual test
Posted by Akihiko Odaki 1 month, 3 weeks ago
On 2026/02/16 20:14, Marc-André Lureau wrote:
> Hi
> 
> This is the combination of the two earlier series:
> [PATCH 00/37] audio: cleanups & add a manual test
> [PATCH 00/43] audio: more cleanups (2/2 for 11.0)
> 
> Patches missing r-b trailers:
> - scripts/modinfo: use argparse
> - scripts/modinfo: make --devices optional
> - scripts/modinfo: add --skip-missing-deps
> - util: add some extra stubs for qemu modules initialization
> - tests: start manual audio backend test
> - audio: use DEFINE_TYPES
> - audio: replace type_init() with DEFINE_TYPES
> - audio: keep a strong reference on the backend
> - replay: remove dependency on audio/
> - audio: fix leak of audio capture name
> 
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>

This is a huge but nice cleanup:

Reviewed-by: Akihiko Odaki <odaki@rsg.ci.i.u-tokyo.ac.jp>