diff options
author | Axel Lin <axel.lin@ingics.com> | 2015-05-10 11:35:06 +0800 |
---|---|---|
committer | Luis Henriques <luis.henriques@canonical.com> | 2015-07-09 14:36:03 +0100 |
commit | f1e1682574190f4c321e20b0760aeb7dfb32ded2 (patch) | |
tree | 591696cb566d65beb973fedd2ccb2e4bdd9fccb7 /sound | |
parent | fd4a5417599b6eee3218ebe5a4f1920ba452624c (diff) | |
download | linux-stable-f1e1682574190f4c321e20b0760aeb7dfb32ded2.tar.gz linux-stable-f1e1682574190f4c321e20b0760aeb7dfb32ded2.tar.bz2 linux-stable-f1e1682574190f4c321e20b0760aeb7dfb32ded2.zip |
ASoC: wm8737: Fixup setting VMID Impedance control register
commit 14ba3ec1de043260cecd9e828ea2e3a0ad302893 upstream.
According to the datasheet:
R10 (0Ah) VMID Impedance Control
BIT 3:2 VMIDSEL DEFAULT 00
DESCRIPTION: VMID impedance selection control
00: 75kΩ output
01: 300kΩ output
10: 2.5kΩ output
WM8737_VMIDSEL_MASK is 0xC (VMIDSEL - [3:2]),
so it needs to left shift WM8737_VMIDSEL_SHIFT bits for setting these bits.
Signed-off-by: Axel Lin <axel.lin@ingics.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Luis Henriques <luis.henriques@canonical.com>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/codecs/wm8737.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/soc/codecs/wm8737.c b/sound/soc/codecs/wm8737.c index b27f26cdc049..daa8e70c41d8 100644 --- a/sound/soc/codecs/wm8737.c +++ b/sound/soc/codecs/wm8737.c @@ -494,7 +494,8 @@ static int wm8737_set_bias_level(struct snd_soc_codec *codec, /* Fast VMID ramp at 2*2.5k */ snd_soc_update_bits(codec, WM8737_MISC_BIAS_CONTROL, - WM8737_VMIDSEL_MASK, 0x4); + WM8737_VMIDSEL_MASK, + 2 << WM8737_VMIDSEL_SHIFT); /* Bring VMID up */ snd_soc_update_bits(codec, WM8737_POWER_MANAGEMENT, @@ -508,7 +509,8 @@ static int wm8737_set_bias_level(struct snd_soc_codec *codec, /* VMID at 2*300k */ snd_soc_update_bits(codec, WM8737_MISC_BIAS_CONTROL, - WM8737_VMIDSEL_MASK, 2); + WM8737_VMIDSEL_MASK, + 1 << WM8737_VMIDSEL_SHIFT); break; |