On 27/01/2026 18:25, [email protected] wrote:

From: Marc-André Lureau <[email protected]>

Signed-off-by: Marc-André Lureau <[email protected]>
---
  audio/audio_template.h  | 10 +++++-----
  audio/audio-mixeng-be.c |  9 ---------
  audio/trace-events      |  1 +
  3 files changed, 6 insertions(+), 14 deletions(-)

diff --git a/audio/audio_template.h b/audio/audio_template.h
index c47a2f202f0..e884c8e9b1a 100644
--- a/audio/audio_template.h
+++ b/audio/audio_template.h
@@ -556,11 +556,11 @@ static SW *glue(audio_mixeng_backend_open_, TYPE) (
      sw->callback.fn = callback_fn;
      sw->callback.opaque = callback_opaque;
-#ifdef DEBUG_AUDIO
-    dolog ("%s\n", name);
-    audio_pcm_print_info ("hw", &sw->hw->info);
-    audio_pcm_print_info ("sw", &sw->info);
-#endif
+    trace_audio_voice_pair(G_STRINGIFY(TYPE), name,
+                           AudioFormat_str(sw->hw->info.af),
+                           sw->hw->info.freq, sw->hw->info.nchannels,
+                           AudioFormat_str(sw->info.af),
+                           sw->info.freq, sw->info.nchannels);

A little unsure of the "pair" naming here?

      return sw;
diff --git a/audio/audio-mixeng-be.c b/audio/audio-mixeng-be.c
index 5303c08a285..5165768a531 100644
--- a/audio/audio-mixeng-be.c
+++ b/audio/audio-mixeng-be.c
@@ -620,15 +620,6 @@ static size_t audio_pcm_sw_write(SWVoiceOut *sw, void 
*buf, size_t buf_len)
      return total_in * sw->info.bytes_per_frame;
  }
-#ifdef DEBUG_AUDIO
-static void audio_pcm_print_info (const char *cap, struct audio_pcm_info *info)
-{
-    dolog("%s: %s, freq %d, nchan %d\n",
-          cap, AudioFormat_str(info->af), info->freq,
-          info->nchannels);
-}
-#endif
-
  #define DAC
  #include "audio_template.h"
  #undef DAC
diff --git a/audio/trace-events b/audio/trace-events
index 7a73d6eb84f..ed04792d508 100644
--- a/audio/trace-events
+++ b/audio/trace-events
@@ -74,3 +74,4 @@ audio_out_played(size_t played) "played=%zu"
  # audio_template.h
  audio_open_out(const char *name, int freq, int nchannels, int fmt) "open %s, freq 
%d, nchannels %d, fmt %d"
  audio_open_in(const char *name, int freq, int nchannels, int fmt) "open %s, freq 
%d, nchannels %d, fmt %d"
+audio_voice_pair(const char *type, const char *name, const char *hw_fmt, int hw_freq, 
int hw_nchannels, const char *sw_fmt, int sw_freq, int sw_nchannels) "%s: name=%s 
hw=%s/%d/%d sw=%s/%d/%d"

Otherwise:

Reviewed-by: Mark Cave-Ayland <[email protected]>


ATB,

Mark.


Reply via email to