2019-05-31 09:29:29

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [BISECT] No audio after "ASoC: core: use component driver name as component name"

Hi,

Bisect points to commit b19671d6caf1ac393681864d5d85dda9fa99a448
Author: Tzung-Bi Shih <[email protected]>
Date: Wed May 29 14:22:14 2019 +0800
ASoC: core: use component driver name as component name

as a reason of failure of missing Audio card on Odroid XU3 board
(ARMv7, Exynos5422,
max98090 codec). Full kernel log:
https://krzk.eu/#/builders/1/builds/3349/steps/14/logs/serial0

The problem might be in component name. The driver->name and
fmt_single_name(dev, &component->id) are:
snd_dmaengine_pcm != 3830000.i2s
snd_dmaengine_pcm != 3830000.i2s-sec
samsung-i2s != 3830000.i2s

This commit should not go in without fixing the users of old
behavior... I could adjust the platform names for primary and
secondary links... but now it looks like two components will have the
same name.

Best regards,
Krzysztof


2019-05-31 10:21:52

by Tzung-Bi Shih

[permalink] [raw]
Subject: Re: [BISECT] No audio after "ASoC: core: use component driver name as component name"

On Fri, May 31, 2019 at 5:27 PM Krzysztof Kozlowski <[email protected]> wrote:
> The problem might be in component name. The driver->name and
> fmt_single_name(dev, &component->id) are:
> snd_dmaengine_pcm != 3830000.i2s
> snd_dmaengine_pcm != 3830000.i2s-sec
> samsung-i2s != 3830000.i2s
>
> This commit should not go in without fixing the users of old
> behavior... I could adjust the platform names for primary and
> secondary links... but now it looks like two components will have the
> same name.
That is because the two component drivers used the same name in
somehow. But yes, we should not have the commit without fixing
potential errors for users depend on old behavior.

Could you send a patch to revert the commit b19671d6caf1?

2019-05-31 13:45:52

by Sylwester Nawrocki

[permalink] [raw]
Subject: Re: [BISECT] No audio after "ASoC: core: use component driver name as component name"

On 5/31/19 12:20, Tzung-Bi Shih wrote:
> On Fri, May 31, 2019 at 5:27 PM Krzysztof Kozlowski <[email protected]> wrote:
>> The problem might be in component name. The driver->name and
>> fmt_single_name(dev, &component->id) are:
>> snd_dmaengine_pcm != 3830000.i2s
>> snd_dmaengine_pcm != 3830000.i2s-sec
>> samsung-i2s != 3830000.i2s
>>
>> This commit should not go in without fixing the users of old
>> behavior... I could adjust the platform names for primary and
>> secondary links... but now it looks like two components will have the
>> same name.
>
> That is because the two component drivers used the same name in
> somehow. But yes, we should not have the commit without fixing
> potential errors for users depend on old behavior.

There are 2 platform devices (3830000.i2s, 3830000.i2s-sec), for each
a platform/DMA component is created. For 3830000.i2s there is also
a component with 2 CPU DAIs registered.

If we derive the platform/DMA component name from the component's driver
name then we end up with non unique Platform component names
(snd_dmaengine_pcm) and subsequently we fail to assign Platform component
to DAI links.

Here is list of components before the patch:

# cat /sys/kernel/debug/asoc/components
3830000.i2s
3830000.i2s-sec
3830000.i2s
hdmi-audio-codec.3.auto
max98090.5-0010
snd-soc-dummy
snd-soc-dummy

And after the patch:

root@target:~# cat /sys/kernel/debug/asoc/components
samsung-i2s
snd_dmaengine_pcm
snd_dmaengine_pcm
hdmi-audio-codec.3.auto
max98090.5-0010
snd-soc-dummy
snd-soc-dummy