-
Notifications
You must be signed in to change notification settings - Fork 177
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
USB-Audio
: Wrong S/PDIF (iec958
) input and output
#292
Comments
At first, it's a bit late to change this configuration scheme now. If we revert the database as you suggest, the hardware with S/PDIF will not work (regression), because there's no collection of this data. I think that the point was to enable all features by default. @tiwai ? We are moving to UCM anyway, so we can be more careful there. |
So you confirm that we can't know how many S/PDIF inputs and outputs a device have other than by having an internal database that maps his name to this number of inputs/outputs?
I don't know UCM well, how it helps to be more careful? |
I am new to the Linux sound system. As I understand, USB sound cards doesn't directly tell the kernel or alsa-lib how many S/PDIF inputs and outputs they have. But they obviously tell their "brand name" like "Plantronics USB Headset" or "HP Digital Stereo Headset" for example.
To present the correct number of S/PDIF inputs and outputs to the rest of the userspace, alsa-lib seems to maintain a kind of known devices database in
src/conf/cards/USB-Audio.conf
.If a USB card brand is not known in this file, alsa-lib always present a single S/PDIF input and a single S/PDIF output. If the index of this card is
1
for example,snd_pcm_open(&pcm, "iec958:1", SND_PCM_STREAM_PLAYBACK, 0)
andsnd_pcm_open(&pcm, "iec958:1", SND_PCM_STREAM_CAPTURE, 0)
will always return 0 even if the USB device doesn't have a real S/PDIF input or output.My question is why this is the default behavior? We are in a "every USB cards have S/PDIF, except those who are known in
USB-Audio.conf
" logic. I think it should be "None USB card has S/PDIF except those who are known for it inUSB-Audio.conf
" because USB devices without S/PDIF are much more common.Cf https://bugs.launchpad.net/ubuntu/+source/alsa-lib/+bug/1002952
Thank you!
The text was updated successfully, but these errors were encountered: