public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dmitry Osipenko <digetx@gmail.com>
To: Jaroslav Kysela <perex@perex.cz>, Mark Brown <broonie@kernel.org>
Cc: Thierry Reding <thierry.reding@gmail.com>,
	Jonathan Hunter <jonathanh@nvidia.com>,
	Takashi Iwai <tiwai@suse.com>, Ion Agorria <ion@agorria.com>,
	Svyatoslav Ryhel <clamor95@gmail.com>,
	Frank Rowand <frowand.list@gmail.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	linux-tegra@vger.kernel.org, devicetree@vger.kernel.org,
	alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
	Rob Herring <robh@kernel.org>
Subject: Re: Question about Tegra UCMs
Date: Wed, 19 May 2021 16:15:43 +0300	[thread overview]
Message-ID: <d5944fc0-4f8a-9881-c336-b418d76540c5@gmail.com> (raw)
In-Reply-To: <562efe35-dd91-12a0-96a5-b8f4f34ea153@perex.cz>

19.05.2021 14:13, Jaroslav Kysela пишет:
> 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.

The current name isn't auto-generated, it's specified via the
nvidia,model device-tree property.

> 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.

I will create the PR, thank you very much. It's important problem which
can't be postponed anymore since sound doesn't work without UCMs on
Tegra devices.

  reply	other threads:[~2021-05-19 13:15 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-18  0:13 [PATCH v1 0/2] Unify NVIDIA Tegra ASoC machine drivers Dmitry Osipenko
2021-05-18  0:13 ` [PATCH v1 1/2] of: base: Export of_device_compatible_match() Dmitry Osipenko
2021-05-18 18:14   ` Rob Herring
2021-05-18  0:13 ` [PATCH v1 2/2] ASoC: tegra: Unify ASoC machine drivers Dmitry Osipenko
2021-05-18 18:09   ` Rob Herring
2021-05-18 18:34     ` Mark Brown
2021-05-18 20:16       ` Dmitry Osipenko
2021-05-19 20:09         ` Mark Brown
2021-05-18 22:31       ` Question about Tegra UCMs Dmitry Osipenko
2021-05-19 11:13         ` Jaroslav Kysela
2021-05-19 13:15           ` Dmitry Osipenko [this message]
2021-05-19 11:38         ` Mark Brown
2021-05-19 13:19           ` Dmitry Osipenko
2021-05-18 20:11     ` [PATCH v1 2/2] ASoC: tegra: Unify ASoC machine drivers Dmitry Osipenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d5944fc0-4f8a-9881-c336-b418d76540c5@gmail.com \
    --to=digetx@gmail.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=clamor95@gmail.com \
    --cc=devicetree@vger.kernel.org \
    --cc=frowand.list@gmail.com \
    --cc=ion@agorria.com \
    --cc=jonathanh@nvidia.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=robh@kernel.org \
    --cc=thierry.reding@gmail.com \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox