]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - queue-4.4/asoc-max98090-fix-restore-of-dapm-muxes.patch
5.1-stable patches
[thirdparty/kernel/stable-queue.git] / queue-4.4 / asoc-max98090-fix-restore-of-dapm-muxes.patch
CommitLineData
0e6eeba7
GKH
1From ecb2795c08bc825ebd604997e5be440b060c5b18 Mon Sep 17 00:00:00 2001
2From: Jon Hunter <jonathanh@nvidia.com>
3Date: Wed, 1 May 2019 15:29:38 +0100
4Subject: ASoC: max98090: Fix restore of DAPM Muxes
5
6From: Jon Hunter <jonathanh@nvidia.com>
7
8commit ecb2795c08bc825ebd604997e5be440b060c5b18 upstream.
9
10The max98090 driver defines 3 DAPM muxes; one for the right line output
11(LINMOD Mux), one for the left headphone mixer source (MIXHPLSEL Mux)
12and one for the right headphone mixer source (MIXHPRSEL Mux). The same
13bit is used for the mux as well as the DAPM enable, and although the mux
14can be correctly configured, after playback has completed, the mux will
15be reset during the disable phase. This is preventing the state of these
16muxes from being saved and restored correctly on system reboot. Fix this
17by marking these muxes as SND_SOC_NOPM.
18
19Note this has been verified this on the Tegra124 Nyan Big which features
20the MAX98090 codec.
21
22Signed-off-by: Jon Hunter <jonathanh@nvidia.com>
23Signed-off-by: Mark Brown <broonie@kernel.org>
24Cc: stable@vger.kernel.org
25Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
26
27---
28 sound/soc/codecs/max98090.c | 12 ++++++------
29 1 file changed, 6 insertions(+), 6 deletions(-)
30
31--- a/sound/soc/codecs/max98090.c
32+++ b/sound/soc/codecs/max98090.c
33@@ -1209,14 +1209,14 @@ static const struct snd_soc_dapm_widget
34 &max98090_right_rcv_mixer_controls[0],
35 ARRAY_SIZE(max98090_right_rcv_mixer_controls)),
36
37- SND_SOC_DAPM_MUX("LINMOD Mux", M98090_REG_LOUTR_MIXER,
38- M98090_LINMOD_SHIFT, 0, &max98090_linmod_mux),
39+ SND_SOC_DAPM_MUX("LINMOD Mux", SND_SOC_NOPM, 0, 0,
40+ &max98090_linmod_mux),
41
42- SND_SOC_DAPM_MUX("MIXHPLSEL Mux", M98090_REG_HP_CONTROL,
43- M98090_MIXHPLSEL_SHIFT, 0, &max98090_mixhplsel_mux),
44+ SND_SOC_DAPM_MUX("MIXHPLSEL Mux", SND_SOC_NOPM, 0, 0,
45+ &max98090_mixhplsel_mux),
46
47- SND_SOC_DAPM_MUX("MIXHPRSEL Mux", M98090_REG_HP_CONTROL,
48- M98090_MIXHPRSEL_SHIFT, 0, &max98090_mixhprsel_mux),
49+ SND_SOC_DAPM_MUX("MIXHPRSEL Mux", SND_SOC_NOPM, 0, 0,
50+ &max98090_mixhprsel_mux),
51
52 SND_SOC_DAPM_PGA("HP Left Out", M98090_REG_OUTPUT_ENABLE,
53 M98090_HPLEN_SHIFT, 0, NULL, 0),