2019-12-12 12:24:09

by Mark Brown

[permalink] [raw]
Subject: Re: [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:

> We tested this standard solution using gstreamer and standard ALSA
> tools like aplay, arecord and all these tools unmute needed blocks
> successfully.

> [Alison Wang] I am using aplay. Do you mean I need to add some parameters for aplay or others to unmute the outputs?

Use amixer.


Attachments:
(No filename) (358.00 B)
signature.asc (499.00 B)
Download all attachments

2020-03-19 20:51:24

by Tim Harvey

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Thu, Dec 12, 2019 at 4:24 AM Mark Brown <[email protected]> wrote:
>
> On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:
>
> > We tested this standard solution using gstreamer and standard ALSA
> > tools like aplay, arecord and all these tools unmute needed blocks
> > successfully.
>
> > [Alison Wang] I am using aplay. Do you mean I need to add some parameters for aplay or others to unmute the outputs?
>
> Use amixer.

Marc / Oleksandr,

I can't seem to find the original patch in my mailbox for 631bc8f:
('ASoC: sgtl5000: Fix of unmute outputs on probe') however I find it
breaks sgtl5000 audio output on the Gateworks boards which is still
broken on 5.6-rc6. Was there some follow-up patches that haven't made
it into mainline yet regarding this?

The response above indicates maybe there was an additional ALSA
control perhaps added as a resolution but I don't see any differences
there.

Best Regards,

Tim

2020-03-20 07:27:08

by Marcel Ziswiler

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

Hi Tim

On Thu, 2020-03-19 at 13:49 -0700, Tim Harvey wrote:
> On Thu, Dec 12, 2019 at 4:24 AM Mark Brown <[email protected]>
> wrote:
> > On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:
> >
> > > We tested this standard solution using gstreamer and standard
> > > ALSA
> > > tools like aplay, arecord and all these tools unmute needed
> > > blocks
> > > successfully.
> > > [Alison Wang] I am using aplay. Do you mean I need to add some
> > > parameters for aplay or others to unmute the outputs?
> >
> > Use amixer.
>
> Marc / Oleksandr,
>
> I can't seem to find the original patch in my mailbox for 631bc8f:
> ('ASoC: sgtl5000: Fix of unmute outputs on probe')

I forwarded you that one again. OK?

> however I find it
> breaks sgtl5000 audio output on the Gateworks boards which is still
> broken on 5.6-rc6.

What exactly do you mean by "breaks"? Isn't it that you just need to
unmute stuff e.g. using amixer or using a proper updated asound.state
file with default states for your controls?

> Was there some follow-up patches that haven't made
> it into mainline yet regarding this?

I don't think so. It all works perfectly, not?

> The response above indicates maybe there was an additional ALSA
> control perhaps added as a resolution but I don't see any differences
> there.

Not that I am aware of, no.

> Best Regards,
>
> Tim

Cheers

Marcel

2020-03-20 12:17:05

by Mark Brown

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Thu, Mar 19, 2020 at 01:49:37PM -0700, Tim Harvey wrote:

> The response above indicates maybe there was an additional ALSA
> control perhaps added as a resolution but I don't see any differences
> there.

The response is talking about existing controls that are already in the
driver.


Attachments:
(No filename) (297.00 B)
signature.asc (499.00 B)
Download all attachments

2020-03-20 15:53:36

by Tim Harvey

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Fri, Mar 20, 2020 at 12:26 AM Marcel Ziswiler
<[email protected]> wrote:
>
> Hi Tim
>
> On Thu, 2020-03-19 at 13:49 -0700, Tim Harvey wrote:
> > On Thu, Dec 12, 2019 at 4:24 AM Mark Brown <[email protected]>
> > wrote:
> > > On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:
> > >
> > > > We tested this standard solution using gstreamer and standard
> > > > ALSA
> > > > tools like aplay, arecord and all these tools unmute needed
> > > > blocks
> > > > successfully.
> > > > [Alison Wang] I am using aplay. Do you mean I need to add some
> > > > parameters for aplay or others to unmute the outputs?
> > >
> > > Use amixer.
> >
> > Marc / Oleksandr,
> >
> > I can't seem to find the original patch in my mailbox for 631bc8f:
> > ('ASoC: sgtl5000: Fix of unmute outputs on probe')
>
> I forwarded you that one again. OK?
>
> > however I find it
> > breaks sgtl5000 audio output on the Gateworks boards which is still
> > broken on 5.6-rc6.
>
> What exactly do you mean by "breaks"? Isn't it that you just need to
> unmute stuff e.g. using amixer or using a proper updated asound.state
> file with default states for your controls?

the audio device is in /proc/asound/cards but when I send audio to it
I 'hear' nothing out the normal line-out output.

>
> > Was there some follow-up patches that haven't made
> > it into mainline yet regarding this?
>
> I don't think so. It all works perfectly, not?
>
> > The response above indicates maybe there was an additional ALSA
> > control perhaps added as a resolution but I don't see any differences
> > there.
>
> Not that I am aware of, no.
>

The output of 'amixer' shows nothing different than before this patch
where audio out worked (same controls, same settings on them). I'm
testing this with a buildroot rootfs with no asound.conf (or at least
none that I know of... i'm honestly not clear where all they can be).

Tim

2020-03-20 17:10:12

by Oleksandr Suvorov

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Fri, Mar 20, 2020 at 5:51 PM Tim Harvey <[email protected]> wrote:
>
> On Fri, Mar 20, 2020 at 12:26 AM Marcel Ziswiler
> <[email protected]> wrote:
> >
> > Hi Tim
> >
> > On Thu, 2020-03-19 at 13:49 -0700, Tim Harvey wrote:
> > > On Thu, Dec 12, 2019 at 4:24 AM Mark Brown <[email protected]>
> > > wrote:
> > > > On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:
> > > >
> > > > > We tested this standard solution using gstreamer and standard
> > > > > ALSA
> > > > > tools like aplay, arecord and all these tools unmute needed
> > > > > blocks
> > > > > successfully.
> > > > > [Alison Wang] I am using aplay. Do you mean I need to add some
> > > > > parameters for aplay or others to unmute the outputs?
> > > >
> > > > Use amixer.
> > >
> > > Marc / Oleksandr,
> > >
> > > I can't seem to find the original patch in my mailbox for 631bc8f:
> > > ('ASoC: sgtl5000: Fix of unmute outputs on probe')
> >
> > I forwarded you that one again. OK?
> >
> > > however I find it
> > > breaks sgtl5000 audio output on the Gateworks boards which is still
> > > broken on 5.6-rc6.
> >
> > What exactly do you mean by "breaks"? Isn't it that you just need to
> > unmute stuff e.g. using amixer or using a proper updated asound.state
> > file with default states for your controls?
>
> the audio device is in /proc/asound/cards but when I send audio to it
> I 'hear' nothing out the normal line-out output.
>
> >
> > > Was there some follow-up patches that haven't made
> > > it into mainline yet regarding this?
> >
> > I don't think so. It all works perfectly, not?
> >
> > > The response above indicates maybe there was an additional ALSA
> > > control perhaps added as a resolution but I don't see any differences
> > > there.
> >
> > Not that I am aware of, no.
> >
>
> The output of 'amixer' shows nothing different than before this patch
> where audio out worked (same controls, same settings on them). I'm
> testing this with a buildroot rootfs with no asound.conf (or at least
> none that I know of... i'm honestly not clear where all they can be).

Tim, did you try to unmute the output with amixer?

Could you provide the output of your amixer with and without this patch?

Before this patch, the driver unmuted HP, LO, and ADC unconditionally
on load (while it just had to set up ZCD bits).
Now HP, LO, ADC remain muted until one unmutes them using standard
ALSA tools/interfaces.
ALSA mute/unmute controls for these outputs have been presenting in
the kernel for a long time. Please, just use them.

>
> Tim
--
Best regards
Oleksandr Suvorov

Toradex AG
Ebenaustrasse 10 | 6048 Horw | Switzerland | T: +41 41 500 48 00

2020-03-20 22:51:59

by Tim Harvey

[permalink] [raw]
Subject: Re: [alsa-devel] [EXT] Re: [PATCH] ASoC: sgtl5000: Revert "ASoC: sgtl5000: Fix of unmute outputs on probe"

On Fri, Mar 20, 2020 at 10:06 AM Oleksandr Suvorov
<[email protected]> wrote:
>
> On Fri, Mar 20, 2020 at 5:51 PM Tim Harvey <[email protected]> wrote:
> >
> > On Fri, Mar 20, 2020 at 12:26 AM Marcel Ziswiler
> > <[email protected]> wrote:
> > >
> > > Hi Tim
> > >
> > > On Thu, 2020-03-19 at 13:49 -0700, Tim Harvey wrote:
> > > > On Thu, Dec 12, 2019 at 4:24 AM Mark Brown <[email protected]>
> > > > wrote:
> > > > > On Thu, Dec 12, 2019 at 10:46:31AM +0000, Alison Wang wrote:
> > > > >
> > > > > > We tested this standard solution using gstreamer and standard
> > > > > > ALSA
> > > > > > tools like aplay, arecord and all these tools unmute needed
> > > > > > blocks
> > > > > > successfully.
> > > > > > [Alison Wang] I am using aplay. Do you mean I need to add some
> > > > > > parameters for aplay or others to unmute the outputs?
> > > > >
> > > > > Use amixer.
> > > >
> > > > Marc / Oleksandr,
> > > >
> > > > I can't seem to find the original patch in my mailbox for 631bc8f:
> > > > ('ASoC: sgtl5000: Fix of unmute outputs on probe')
> > >
> > > I forwarded you that one again. OK?
> > >
> > > > however I find it
> > > > breaks sgtl5000 audio output on the Gateworks boards which is still
> > > > broken on 5.6-rc6.
> > >
> > > What exactly do you mean by "breaks"? Isn't it that you just need to
> > > unmute stuff e.g. using amixer or using a proper updated asound.state
> > > file with default states for your controls?
> >
> > the audio device is in /proc/asound/cards but when I send audio to it
> > I 'hear' nothing out the normal line-out output.
> >
> > >
> > > > Was there some follow-up patches that haven't made
> > > > it into mainline yet regarding this?
> > >
> > > I don't think so. It all works perfectly, not?
> > >
> > > > The response above indicates maybe there was an additional ALSA
> > > > control perhaps added as a resolution but I don't see any differences
> > > > there.
> > >
> > > Not that I am aware of, no.
> > >
> >
> > The output of 'amixer' shows nothing different than before this patch
> > where audio out worked (same controls, same settings on them). I'm
> > testing this with a buildroot rootfs with no asound.conf (or at least
> > none that I know of... i'm honestly not clear where all they can be).
>
> Tim, did you try to unmute the output with amixer?
>
> Could you provide the output of your amixer with and without this patch?
>
> Before this patch, the driver unmuted HP, LO, and ADC unconditionally
> on load (while it just had to set up ZCD bits).
> Now HP, LO, ADC remain muted until one unmutes them using standard
> ALSA tools/interfaces.
> ALSA mute/unmute controls for these outputs have been presenting in
> the kernel for a long time. Please, just use them.
>

Oleksandr,

When I first bisected to this I must have done something wrong as I
thought amixer settings showed the same before and after - I see that
I'm wrong about that. I see the differences now with HP, LO, and ADC
muted by default. I agree using amixer controls is fine.

Sorry for the noise!

Tim