From: Ajit Kumar Pandey <AjitKumar.Pandey@amd.com>
To: Mark Brown <broonie@kernel.org>
Cc: alsa-devel@alsa-project.org, Vijendar.Mukunda@amd.com,
Alexander.Deucher@amd.com, Basavaraj.Hiregoudar@amd.com,
Sunil-kumar.Dommati@amd.com, Liam Girdwood <lgirdwood@gmail.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] ASoC: max98357a: Add mixer control to mute/unmute speaker
Date: Thu, 16 Dec 2021 17:54:45 +0530 [thread overview]
Message-ID: <3ec805fc-07cc-6091-551a-771dffe459d0@amd.com> (raw)
In-Reply-To: <YbEYVq+uvIcoxqko@sirena.org.uk>
On 12/9/2021 2:10 AM, Mark Brown wrote:
> Actually now I look again the only control interface this driver has is
> GPIOs but it does expose a digital interface with constraints as input
> so doesn't fit within simple-amplifier. However this is just powering
> off the amplifier to achieve mute rather than a separate mute control so
> it'd probably be better to use a SND_SOC_DAPM_PIN_SWITCH() for the
> Speaker widget to do this, this would also end up addressing Jaroslav's
> thing with the naming as a side effect. Sorry about the confusion there.
Thanks for suggestion. We tried using SND_SOC_DAPM_PIN_SWITCH() for the
speaker widget and it invoke dapm_event callback based on switch i.e
max98357a_sdmode_event() but codec driver isn't enabling/disabling gpios
in such event callback instead they are doing that in dai_ops trigger
callback. In our platform single I2S controller instance (cpu-dai) is
connected to two different endpoints with a single PCM device, hence we
want to switch or enable/disable output based on Machine driver controls
only.
Initially we thought to configure gpio within sdmode_event callback but
there was some pop noise issue reported in one platform with that change
hence reverted. Check
https://patchwork.kernel.org/project/alsa-devel/patch/20200721114232.2812254-1-tzungbi@google.com/#23502085
So we thought of exposing a mixer control to enable/disable amp from UCM
in our platform without breaking existing functionality. Please let us
know any other alternative way if possible.
next prev parent reply other threads:[~2021-12-16 12:25 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-08 18:58 [PATCH] ASoC: max98357a: Add mixer control to mute/unmute speaker Ajit Kumar Pandey
2021-12-08 20:21 ` Mark Brown
2021-12-08 20:40 ` Mark Brown
2021-12-16 12:24 ` Ajit Kumar Pandey [this message]
2021-12-16 13:30 ` Mark Brown
2021-12-17 13:58 ` Ajit Kumar Pandey
2021-12-08 20:25 ` Jaroslav Kysela
2021-12-08 20:33 ` Mark Brown
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=3ec805fc-07cc-6091-551a-771dffe459d0@amd.com \
--to=ajitkumar.pandey@amd.com \
--cc=Alexander.Deucher@amd.com \
--cc=Basavaraj.Hiregoudar@amd.com \
--cc=Sunil-kumar.Dommati@amd.com \
--cc=Vijendar.Mukunda@amd.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--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