On 11. 02. 25 16:12, Amadeusz Sławiński wrote:
Well, those can be set to something better, it's just that ASoC defaults
to DMI if there is no longname provided. So if you have any suggestions,
we can do it while also changing card names.
But do note that it allows for differentiating between different
machines using same card in case we need to do something custom for UCM
on one of them:
2680
access("/usr/share/alsa/ucm2/conf.d/avs_hdaudio/LENOVO-20KH006LPB-
ThinkPadX1Carbon6th.conf",
R_OK) = -1 ENOENT (No such file or directory)
2680 access("/usr/share/alsa/ucm2/conf.d/avs_hdaudio/avs_hdaudio.conf",
R_OK) = -1 ENOENT (No such file or directory)
so while not pretty I'm not sure if we can do any better, without
breaking above possibility. And in most cases UCM based on driver name
should be enough, which looks pretty enough.
UCM can do DMI matching itself now like (copied from acp5x.conf):
....
If.jupiter {
Condition {
Type String
String1 "Jupiter"
String2 "${sys:devices/virtual/dmi/id/product_name}"
}
True {
...
....
The long name path lookup is a relict from the past. ASoC core just
duplicates information which can be already obtained in the user space.
I'm going to rewrite the machine specific links and use the UCM like
matching here. With this, we can turn long name lookups in /usr/share/
alsa/ucm2/ucm.conf off.
Oh, that's nice, should I then also set longname = shortname for our
cards?
I think so. USB and legacy HDA cards add the device path (sysfs) to the long
name or PCI device address like:
Lenovo ThinkPad Thunderbolt 4 Dock USB at usb-0000:00:14.0-4.4.4.4, full speed
HDA NVidia at 0x99000000 irq 19
But if you don't expect multiple instances, I think that name without this
additional identification is enough.
Jaroslav
--
Jaroslav Kysela <perex@xxxxxxxx>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
[Index of Archives]
[Pulseaudio]
[Linux Audio Users]
[ALSA Devel]
[Fedora Desktop]
[Fedora SELinux]
[Big List of Linux Books]
[Yosemite News]
[KDE Users]