Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d055852e authored by Mukund Navada's avatar Mukund Navada Committed by Mark Brown
Browse files

ASoC: core: Double control update err for snd_soc_put_volsw_sx



snd_soc_put_volsw_sx function fails to update second control
if first control is updated by snd_soc_update_bits_locked.

Signed-off-by: default avatarMukund Navada <navada@ti.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@vger.kernel.org
parent 445632ad
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -2786,7 +2786,8 @@ int snd_soc_put_volsw_sx(struct snd_kcontrol *kcontrol,
	val = (ucontrol->value.integer.value[0] + min) & mask;
	val = val << shift;

	if (snd_soc_update_bits_locked(codec, reg, val_mask, val))
	err = snd_soc_update_bits_locked(codec, reg, val_mask, val);
	if (err < 0)
		return err;

	if (snd_soc_volsw_is_stereo(mc)) {