[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <562efe35-dd91-12a0-96a5-b8f4f34ea153@perex.cz>
Date: Wed, 19 May 2021 13:13:53 +0200
From: Jaroslav Kysela <perex@...ex.cz>
To: Dmitry Osipenko <digetx@...il.com>, Mark Brown <broonie@...nel.org>
Cc: Thierry Reding <thierry.reding@...il.com>,
Jonathan Hunter <jonathanh@...dia.com>,
Takashi Iwai <tiwai@...e.com>, Ion Agorria <ion@...rria.com>,
Svyatoslav Ryhel <clamor95@...il.com>,
Frank Rowand <frowand.list@...il.com>,
Liam Girdwood <lgirdwood@...il.com>,
linux-tegra@...r.kernel.org, devicetree@...r.kernel.org,
alsa-devel@...a-project.org, linux-kernel@...r.kernel.org,
Rob Herring <robh@...nel.org>
Subject: Re: Question about Tegra UCMs
Dne 19. 05. 21 v 0:31 Dmitry Osipenko napsal(a):
> Mark, could you please help me to understand the UCM naming scheme that ALSA uses..
>
> About a year ago I tried to complain to Jaroslav Kysela in a comment to the UCM change [1] that it should be breaking the naming scheme of Tegra UCMs, but haven't got a meaningful reply and moved on to other things.
>
> [1] https://github.com/alsa-project/alsa-ucm-conf/commit/8ff2d50745efbb6959324f672460e413f0b618b8
I'm sorry about that, but it's better to create a tracked ticket (issue or
pull request).
> Today I noticed that the naming scheme changed again and I still don't understand what to do about it.
>
> I have two devices:
>
> 1. Acer Picasso tablet that uses "Acer Iconia Tab A500 WM8903" for the card model name.
>
> 2. Google Nexus 7 that uses "ASUS Google Nexus 7 ALC5642".
>
> Previously UCMs were picked up by pulseaudio from these paths:
>
> 1. /usr/share/alsa/ucm2/Acer Iconia Tab A500 WM8903/
> 2. /usr/share/alsa/ucm2/ASUS Google Nexus 7 ALC5642/
>
> Now the lookup paths are changed to:
>
> 1. /usr/share/alsa/ucm2/Acer_Iconia_Tab/
> 2. /usr/share/alsa/ucm2/ASUS_Google_Nex/
Yes, it's based on the driver name (which is incorrectly set /or not set/ in
your case).
Lookup paths (with description):
https://github.com/alsa-project/alsa-ucm-conf/blob/master/ucm2/ucm.conf
The latest scheme is even different - lookups were moved to ucm2/conf.d with
redirection to the more descriptive layered configuration tree structure, so
the other developers can immediately identify the hardware which is
configured. See Qualcomm examples. The long card names does not help us so much.
> Strace shows that pulseaudio searches UCMs only at these paths.
>
> The output of /proc/asound/cards:
>
> 0 [WM8903 ]: Acer_Iconia_Tab - Acer Iconia Tab A500 WM8903
> Acer Iconia Tab A500 WM8903
>
> 0 [ALC5642 ]: ASUS_Google_Nex - ASUS Google Nexus 7 ALC5642
> ASUS Google Nexus 7 ALC5642
Fields are explained in:
https://github.com/alsa-project/alsa-ucm-conf/blob/master/ucm2/README.md
> Is there anything on the kernel side that I could change to get a working naming scheme? If yes, I may try to do something about it in the v2, thanks in advance.
Try to set a meaningful driver name (usually the code handling the ASoC card
creation). It should be very close to the kernel module name (but more user
friendly). The current code for your hardware use the auto-generated driver
name from the ALSA long name.
Then try to reuse the existing configs - for example your Nexus 7 config has
many blocks from codecs/rt5640/* .
Anyway, create a PR so we can discuss the details.
Jaroslav
--
Jaroslav Kysela <perex@...ex.cz>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.
Powered by blists - more mailing lists