diff options
author | Timo Juhani Lindfors <timo.lindfors@iki.fi> | 2011-11-16 19:52:50 -0500 |
---|---|---|
committer | Herton Ronaldo Krzesinski <herton.krzesinski@canonical.com> | 2011-12-12 08:07:04 -0500 |
commit | 00e22b4687ce92b9385a3b9350ce187de0675a6c (patch) | |
tree | 24b532f3ec8909ed9cc89699692124aa26a43e14 /sound/soc/codecs | |
parent | 54dbdca5b613f68eeb72bd1dee27b19439de6860 (diff) |
ASoC: wm8753: Skip noop reconfiguration of DAI mode
BugLink: http://bugs.launchpad.net/bugs/902312
commit 2391a0e06789a3f1718dee30b282562f7ed28c87 upstream.
This patch makes it possible to set DAI mode to its currently applied
value even if codec is active. This is necessary to allow
aplay -t raw -r 44100 -f S16_LE -c 2 < /dev/urandom &
alsactl store -f backup.state
alsactl restore -f backup.state
to work without returning errors. This patch is based on a patch sent
by Klaus Kurzmann <mok@fluxnetz.de>.
Signed-off-by: Timo Juhani Lindfors <timo.lindfors@iki.fi>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r-- | sound/soc/codecs/wm8753.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c index aa091a0d818..66d18a3e57f 100644 --- a/sound/soc/codecs/wm8753.c +++ b/sound/soc/codecs/wm8753.c | |||
@@ -189,6 +189,9 @@ static int wm8753_set_dai(struct snd_kcontrol *kcontrol, | |||
189 | struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); | 189 | struct wm8753_priv *wm8753 = snd_soc_codec_get_drvdata(codec); |
190 | u16 ioctl; | 190 | u16 ioctl; |
191 | 191 | ||
192 | if (wm8753->dai_func == ucontrol->value.integer.value[0]) | ||
193 | return 0; | ||
194 | |||
192 | if (codec->active) | 195 | if (codec->active) |
193 | return -EBUSY; | 196 | return -EBUSY; |
194 | 197 | ||