summary refs log tree commit diff
path: root/sound
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2014-02-22 18:27:17 +0100
committerMark Brown <broonie@linaro.org>2014-02-23 10:48:55 +0900
commit70ff00f82a6af0ff68f8f7b411738634ce2f20d0 (patch)
tree0f443c6417f5ccc108af7f7be4c3290fda192669 /sound
parent025c3fa9256d4c54506b7a29dc3befac54f5c68d (diff)
downloadlinux-70ff00f82a6af0ff68f8f7b411738634ce2f20d0.tar.gz
ASoC: sta32x: Fix cache sync
codec->control_data contains a pointer to the regmap struct of the device, not
to the device private data. Use snd_soc_codec_get_drvdata() instead.

The issue was introduced in commit 29fdf4fbbe ("ASoC: sta32x: Convert to
regmap").

Fixes: 29fdf4fbbe (ASoC: sta32x: Convert to regmap)
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Mark Brown <broonie@linaro.org>
Cc: stable@vger.kernel.org
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/sta32x.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/soc/codecs/sta32x.c b/sound/soc/codecs/sta32x.c
index 42c5b458b046..ea78c172538c 100644
--- a/sound/soc/codecs/sta32x.c
+++ b/sound/soc/codecs/sta32x.c
@@ -331,7 +331,7 @@ static int sta32x_sync_coef_shadow(struct snd_soc_codec *codec)
 
 static int sta32x_cache_sync(struct snd_soc_codec *codec)
 {
-	struct sta32x_priv *sta32x = codec->control_data;
+	struct sta32x_priv *sta32x = snd_soc_codec_get_drvdata(codec);
 	unsigned int mute;
 	int rc;