All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
@ 2022-06-03 11:50 Mark Brown
  2022-06-06  9:39 ` Richard Fitzgerald
  2022-06-07 10:45 ` Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: Mark Brown @ 2022-06-03 11:50 UTC (permalink / raw)
  To: Liam Girdwood, Charles Keepax, Simon Trimmer
  Cc: patches, alsa-devel, Mark Brown

Currently wm_adsp_fw_put() returns 0 rather than 1 when updating the value
of the control, meaning that no event is generated to userspace. Fix this
by setting the default return value to 1, the code already exits early with
a return value of 0 if the value is unchanged.

Signed-off-by: Mark Brown <broonie@kernel.org>
---
 sound/soc/codecs/wm_adsp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c
index 7973a75cac05..6d7fd88243aa 100644
--- a/sound/soc/codecs/wm_adsp.c
+++ b/sound/soc/codecs/wm_adsp.c
@@ -333,7 +333,7 @@ int wm_adsp_fw_put(struct snd_kcontrol *kcontrol,
 	struct snd_soc_component *component = snd_soc_kcontrol_component(kcontrol);
 	struct soc_enum *e = (struct soc_enum *)kcontrol->private_value;
 	struct wm_adsp *dsp = snd_soc_component_get_drvdata(component);
-	int ret = 0;
+	int ret = 1;
 
 	if (ucontrol->value.enumerated.item[0] == dsp[e->shift_l].fw)
 		return 0;
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
  2022-06-03 11:50 [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put() Mark Brown
@ 2022-06-06  9:39 ` Richard Fitzgerald
  2022-06-07 10:45 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Richard Fitzgerald @ 2022-06-06  9:39 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood, Charles Keepax, Simon Trimmer
  Cc: patches, alsa-devel

On 03/06/2022 12:50, Mark Brown wrote:
> Currently wm_adsp_fw_put() returns 0 rather than 1 when updating the value
> of the control, meaning that no event is generated to userspace. Fix this
> by setting the default return value to 1, the code already exits early with
> a return value of 0 if the value is unchanged.
> 
> Signed-off-by: Mark Brown <broonie@kernel.org>
> ---
>   sound/soc/codecs/wm_adsp.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c
> index 7973a75cac05..6d7fd88243aa 100644
> --- a/sound/soc/codecs/wm_adsp.c
> +++ b/sound/soc/codecs/wm_adsp.c
> @@ -333,7 +333,7 @@ int wm_adsp_fw_put(struct snd_kcontrol *kcontrol,
>   	struct snd_soc_component *component = snd_soc_kcontrol_component(kcontrol);
>   	struct soc_enum *e = (struct soc_enum *)kcontrol->private_value;
>   	struct wm_adsp *dsp = snd_soc_component_get_drvdata(component);
> -	int ret = 0;
> +	int ret = 1;
>   
>   	if (ucontrol->value.enumerated.item[0] == dsp[e->shift_l].fw)
>   		return 0;
> 
Reviewed-by: Richard Fitzgerald <rf@opensource.cirrus.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
  2022-06-03 11:50 [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put() Mark Brown
  2022-06-06  9:39 ` Richard Fitzgerald
@ 2022-06-07 10:45 ` Mark Brown
  1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2022-06-07 10:45 UTC (permalink / raw)
  To: simont, ckeepax, broonie, Liam Girdwood; +Cc: patches, alsa-devel

On Fri, 3 Jun 2022 13:50:03 +0200, Mark Brown wrote:
> Currently wm_adsp_fw_put() returns 0 rather than 1 when updating the value
> of the control, meaning that no event is generated to userspace. Fix this
> by setting the default return value to 1, the code already exits early with
> a return value of 0 if the value is unchanged.
> 
> 

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put()
      commit: 2abdf9f80019e8244d3806ed0e1c9f725e50b452

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-06-07 10:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-03 11:50 [PATCH] ASoC: wm_adsp: Fix event generation for wm_adsp_fw_put() Mark Brown
2022-06-06  9:39 ` Richard Fitzgerald
2022-06-07 10:45 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.