summaryrefslogtreecommitdiffstats
path: root/plugins/alsa/alsa-utils-dump.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/alsa/alsa-utils-dump.c')
-rw-r--r--plugins/alsa/alsa-utils-dump.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/plugins/alsa/alsa-utils-dump.c b/plugins/alsa/alsa-utils-dump.c
index b6c011d..79059ee 100644
--- a/plugins/alsa/alsa-utils-dump.c
+++ b/plugins/alsa/alsa-utils-dump.c
@@ -109,7 +109,7 @@ PUBLIC void AlsaDumpCtlSubdev(SoftMixerT *mixer, snd_ctl_t *handle) {
while (1) {
if (snd_ctl_pcm_next_device(handle, &dev) < 0) {
- AFB_ApiError(mixer->api, "AlsaDumpCard: fail to open subdev card id=%s name=%s", cardId, cardName);
+ AFB_ApiError(mixer->api, "%s: fail to open subdev card id=%s name=%s", __func__, cardId, cardName);
goto OnErrorExit;
}
@@ -119,12 +119,13 @@ PUBLIC void AlsaDumpCtlSubdev(SoftMixerT *mixer, snd_ctl_t *handle) {
// ignore empty device slot
if ((err = snd_ctl_pcm_info(handle, pcminfo)) < 0) {
if (err != -ENOENT)
- AFB_ApiError(mixer->api, "control digital audio info (%s): %s", cardName, snd_strerror(err));
+ AFB_ApiError(mixer->api, "%s: control digital audio info (%s): %s", __func__, cardName, snd_strerror(err));
continue;
}
- AFB_ApiDebug(mixer->api, "AlsaDumpCard card %d: %s [%s], device %d: %s [%s]",
- cardIndex, cardId, cardName, dev, snd_pcm_info_get_id(pcminfo), snd_pcm_info_get_name(pcminfo));
+ AFB_ApiDebug(mixer->api,
+ "%s card %d: %s [%s], device %d: %s [%s]",
+ __func__, cardIndex, cardId, cardName, dev, snd_pcm_info_get_id(pcminfo), snd_pcm_info_get_name(pcminfo));
// loop on subdevices
subdevCount = snd_pcm_info_get_subdevices_count(pcminfo);
@@ -133,12 +134,12 @@ PUBLIC void AlsaDumpCtlSubdev(SoftMixerT *mixer, snd_ctl_t *handle) {
for (unsigned int idx = 0; idx < subdevCount; idx++) {
snd_pcm_info_set_subdevice(pcminfo, idx);
if ((err = snd_ctl_pcm_info(handle, pcminfo)) < 0) {
- AFB_ApiError(mixer->api, "AlsaDumpCard: control digital audio playback info %i: %s", cardIndex, snd_strerror(err));
+ AFB_ApiError(mixer->api, "%s: control digital audio playback info %i: %s", __func__, cardIndex, snd_strerror(err));
} else {
- AFB_ApiDebug(mixer->api, "AlsaDumpCard: -- Subdevice #%d: %s", idx, snd_pcm_info_get_subdevice_name(pcminfo));
+ AFB_ApiDebug(mixer->api, "%s: -- Subdevice #%d: %s", __func__, idx, snd_pcm_info_get_subdevice_name(pcminfo));
}
}
- AFB_ApiDebug(mixer->api, "AlsaDumpCard => subdevice count=%d avaliable=%d", subdevCount, subdevAvail);
+ AFB_ApiDebug(mixer->api, "%s => subdevice count=%d avaliable=%d", __func__, subdevCount, subdevAvail);
}
return;
@@ -153,7 +154,7 @@ PUBLIC void AlsaDumpPcmParams(SoftMixerT *mixer, snd_pcm_hw_params_t *pcmHwParam
snd_output_buffer_open(&output);
snd_pcm_hw_params_dump(pcmHwParams, output);
snd_output_buffer_string(output, &buffer);
- AFB_ApiDebug(mixer->api, "%s:\n%s",__func__, buffer);
+ AFB_ApiDebug(mixer->api, "%s:\n--------------\n%s\n-------------",__func__, buffer);
snd_output_close(output);
}