summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/nau8825.c
diff options
context:
space:
mode:
authorJohn Hsu <KCHSU0@nuvoton.com>2016-03-30 14:57:11 +0800
committerMark Brown <broonie@kernel.org>2016-05-30 16:17:44 +0100
commit3f039169ddc3edb2ecad03034843833d5b5a455f (patch)
treec131f7974f639a6bc0fcd9d3dc4ab7c3add79e1d /sound/soc/codecs/nau8825.c
parenteeef16acf85c2ebce695fb559627d0300396511e (diff)
ASoC: nau8825: assign DAC Ch to match headset L/R
The default value of DAC channel select is reverse in codec. For normal usage, switch the channel select when codec bootup. Signed-off-by: John Hsu <KCHSU0@nuvoton.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/nau8825.c')
-rw-r--r--sound/soc/codecs/nau8825.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/soc/codecs/nau8825.c b/sound/soc/codecs/nau8825.c
index 3eb76c5526dc..81fc97b07751 100644
--- a/sound/soc/codecs/nau8825.c
+++ b/sound/soc/codecs/nau8825.c
@@ -946,6 +946,11 @@ static void nau8825_init_regs(struct nau8825 *nau8825)
NAU8825_RDAC_CLK_DELAY_MASK | NAU8825_RDAC_VREF_MASK,
(0x2 << NAU8825_RDAC_CLK_DELAY_SFT) |
(0x3 << NAU8825_RDAC_VREF_SFT));
+ /* Config L/R channel */
+ regmap_update_bits(nau8825->regmap, NAU8825_REG_DACL_CTRL,
+ NAU8825_DACL_CH_SEL_MASK, NAU8825_DACL_CH_SEL_L);
+ regmap_update_bits(nau8825->regmap, NAU8825_REG_DACR_CTRL,
+ NAU8825_DACL_CH_SEL_MASK, NAU8825_DACL_CH_SEL_R);
}
static const struct regmap_config nau8825_regmap_config = {