]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: dapm: Fix snd_soc_dapm_put_volsw() connect
authorBenoît Thébaudeau <benoit.thebaudeau@advansee.com>
Mon, 18 Jun 2012 20:41:28 +0000 (22:41 +0200)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Fri, 29 Jun 2012 07:13:32 +0000 (08:13 +0100)
commitc29d20485e7031eacebc8071ccfcd6fc4b1b6fe7
tree7a5a4378432af0ee9d970114fb29e9d3e5ed5c6b
parentc81f26b3f07fb4e65bba5c9c916599173e5a5bd6
ASoC: dapm: Fix snd_soc_dapm_put_volsw() connect

snd_soc_dapm_put_volsw() sets connect incorrectly in the case max > 1 with
invert. In that case, the raw disconnect value should be max, which corresponds
to the userspace value 0.

This use case currently does not appear upstream, but it could break
SOC_DAPM_SINGLE() or SOC_DAPM_SINGLE_TLV() elsewhere or in the future.

Signed-off-by: Benoît Thébaudeau <benoit.thebaudeau@advansee.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/soc-dapm.c