Errors while opening or configuring ALSA devices during scan for devices
should not be shown by default (i.e., no sr_err() usage). Non-working
or non-accessible devices (due to permissions or other reasons) will
simply not show up in frontends. Use sr_dbg() instead of sr_err().
- sr_err("Getting %d poll descriptors.", count);
+ sr_spew("Getting %d poll descriptors.", count);
ret = snd_pcm_poll_descriptors(devc->capture_handle, devc->ufds, count);
if (ret < 0) {
sr_err("Unable to obtain poll descriptors: %s.",
ret = snd_pcm_poll_descriptors(devc->capture_handle, devc->ufds, count);
if (ret < 0) {
sr_err("Unable to obtain poll descriptors: %s.",
(void)options;
if ((ret = snd_ctl_card_info_malloc(&info)) < 0) {
(void)options;
if ((ret = snd_ctl_card_info_malloc(&info)) < 0) {
- sr_err("Failed to malloc card info: %s.", snd_strerror(ret));
+ sr_dbg("Failed to malloc card info: %s.", snd_strerror(ret));
return NULL;
}
if ((ret = snd_pcm_info_malloc(&pcminfo) < 0)) {
return NULL;
}
if ((ret = snd_pcm_info_malloc(&pcminfo) < 0)) {
- sr_err("Cannot malloc pcm info: %s.", snd_strerror(ret));
+ sr_dbg("Cannot malloc pcm info: %s.", snd_strerror(ret));
while (snd_card_next(&card) >= 0 && card >= 0) {
snprintf(hwcard, sizeof(hwcard), "hw:%d", card);
if ((ret = snd_ctl_open(&handle, hwcard, 0)) < 0) {
while (snd_card_next(&card) >= 0 && card >= 0) {
snprintf(hwcard, sizeof(hwcard), "hw:%d", card);
if ((ret = snd_ctl_open(&handle, hwcard, 0)) < 0) {
- sr_err("Cannot open (%d): %s.", card, snd_strerror(ret));
+ sr_dbg("Cannot open (%d): %s.", card, snd_strerror(ret));
continue;
}
if ((ret = snd_ctl_card_info(handle, info)) < 0) {
continue;
}
if ((ret = snd_ctl_card_info(handle, info)) < 0) {
- sr_err("Cannot get hardware info (%d): %s.",
+ sr_dbg("Cannot get hardware info (%d): %s.",
card, snd_strerror(ret));
if ((ret = snd_ctl_close(handle)) < 0) {
card, snd_strerror(ret));
if ((ret = snd_ctl_close(handle)) < 0) {
- sr_err("Cannot close device (%d): %s.",
+ sr_dbg("Cannot close device (%d): %s.",
card, snd_strerror(ret));
}
continue;
card, snd_strerror(ret));
}
continue;
snd_pcm_info_set_stream(pcminfo,
SND_PCM_STREAM_CAPTURE);
if ((ret = snd_ctl_pcm_info(handle, pcminfo)) < 0) {
snd_pcm_info_set_stream(pcminfo,
SND_PCM_STREAM_CAPTURE);
if ((ret = snd_ctl_pcm_info(handle, pcminfo)) < 0) {
- sr_err("Cannot get device info (%s): %s.",
+ sr_dbg("Cannot get device info (%s): %s.",
hwdev, snd_strerror(ret));
continue;
}
hwdev, snd_strerror(ret));
continue;
}
di, pcminfo);
}
if ((ret = snd_ctl_close(handle)) < 0) {
di, pcminfo);
}
if ((ret = snd_ctl_close(handle)) < 0) {
- sr_err("Cannot close device (%d): %s.",
+ sr_dbg("Cannot close device (%d): %s.",
card, snd_strerror(ret));
}
}
card, snd_strerror(ret));
}
}