From: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
To: Johan Hovold <johan+linaro@kernel.org>, Mark Brown <broonie@kernel.org>
Cc: Banajit Goswami <bgoswami@quicinc.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
alsa-devel@alsa-project.org, linux-sound@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 5/5] ASoC: codecs: wcd9335: drop unused gain hack remnant
Date: Fri, 19 Jan 2024 07:46:57 +0000 [thread overview]
Message-ID: <456eaa3a-7f0c-4b28-aeca-2af60475011a@linaro.org> (raw)
In-Reply-To: <20240118165811.13672-6-johan+linaro@kernel.org>
On 18/01/2024 16:58, Johan Hovold wrote:
> The vendor driver appears to be modifying the gain settings behind the
> back of user space but these hacks never made it upstream except for
> some essentially dead code that adds a constant zero to the current gain
> setting on DAPM events.
>
> Note that the volume registers still need to be written after enabling
> clocks in order for any prior updates to take effect.
>
> Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
> ---
lgtm,
Reviewed-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
--srini
> sound/soc/codecs/wcd9335.c | 4 ----
> 1 file changed, 4 deletions(-)
>
> diff --git a/sound/soc/codecs/wcd9335.c b/sound/soc/codecs/wcd9335.c
> index 43c648efd0d9..deb15b95992d 100644
> --- a/sound/soc/codecs/wcd9335.c
> +++ b/sound/soc/codecs/wcd9335.c
> @@ -3033,7 +3033,6 @@ static int wcd9335_codec_enable_mix_path(struct snd_soc_dapm_widget *w,
> {
> struct snd_soc_component *comp = snd_soc_dapm_to_component(w->dapm);
> u16 gain_reg;
> - int offset_val = 0;
> int val = 0;
>
> switch (w->reg) {
> @@ -3073,7 +3072,6 @@ static int wcd9335_codec_enable_mix_path(struct snd_soc_dapm_widget *w,
> switch (event) {
> case SND_SOC_DAPM_POST_PMU:
> val = snd_soc_component_read(comp, gain_reg);
> - val += offset_val;
> snd_soc_component_write(comp, gain_reg, val);
> break;
> case SND_SOC_DAPM_POST_PMD:
> @@ -3294,7 +3292,6 @@ static int wcd9335_codec_enable_interpolator(struct snd_soc_dapm_widget *w,
> u16 gain_reg;
> u16 reg;
> int val;
> - int offset_val = 0;
>
> if (!(snd_soc_dapm_widget_name_cmp(w, "RX INT0 INTERP"))) {
> reg = WCD9335_CDC_RX0_RX_PATH_CTL;
> @@ -3337,7 +3334,6 @@ static int wcd9335_codec_enable_interpolator(struct snd_soc_dapm_widget *w,
> case SND_SOC_DAPM_POST_PMU:
> wcd9335_config_compander(comp, w->shift, event);
> val = snd_soc_component_read(comp, gain_reg);
> - val += offset_val;
> snd_soc_component_write(comp, gain_reg, val);
> break;
> case SND_SOC_DAPM_POST_PMD:
prev parent reply other threads:[~2024-01-19 7:47 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-18 16:58 [PATCH v3 0/5] ASoC: qcom: volume fixes and codec cleanups Johan Hovold
2024-01-18 16:58 ` [PATCH v3 1/5] ASoC: codecs: wsa883x: fix PA volume control Johan Hovold
2024-01-18 17:24 ` Mark Brown
2024-01-19 7:34 ` Johan Hovold
2024-01-19 7:14 ` Srinivas Kandagatla
2024-01-19 7:49 ` Johan Hovold
2024-01-18 16:58 ` [PATCH v3 2/5] ASoC: codecs: wsa883x: lower default PA gain Johan Hovold
2024-01-18 17:21 ` Mark Brown
2024-01-19 7:57 ` Johan Hovold
2024-01-19 7:15 ` Srinivas Kandagatla
2024-01-19 8:00 ` Johan Hovold
2024-01-18 16:58 ` [PATCH v3 3/5] ASoC: qcom: sc8280xp: limit speaker volumes Johan Hovold
2024-01-19 7:37 ` Srinivas Kandagatla
2024-01-19 8:06 ` Johan Hovold
2024-01-18 16:58 ` [PATCH v3 4/5] ASoC: codecs: lpass-wsa-macro: fix compander volume hack Johan Hovold
2024-01-19 7:45 ` Srinivas Kandagatla
2024-01-19 8:10 ` Johan Hovold
2024-01-18 16:58 ` [PATCH v3 5/5] ASoC: codecs: wcd9335: drop unused gain hack remnant Johan Hovold
2024-01-19 7:46 ` Srinivas Kandagatla [this message]
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=456eaa3a-7f0c-4b28-aeca-2af60475011a@linaro.org \
--to=srinivas.kandagatla@linaro.org \
--cc=alsa-devel@alsa-project.org \
--cc=bgoswami@quicinc.com \
--cc=broonie@kernel.org \
--cc=johan+linaro@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@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
all inboxes | Powered by JetHome®