From 4a3e05653b16cd108de1f717a209bd4fd437a114 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=E9=82=B1=E5=BB=BA=E6=96=8C?= Date: Mon, 8 Jul 2013 15:15:52 +0800 Subject: [PATCH] rt5631 : add pcm playback volume config --- sound/soc/codecs/rt5631.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sound/soc/codecs/rt5631.c b/sound/soc/codecs/rt5631.c index 1206c0d7bd88..99c5ab9a33ac 100755 --- a/sound/soc/codecs/rt5631.c +++ b/sound/soc/codecs/rt5631.c @@ -26,7 +26,7 @@ #include #include #include - +#include #include "rt5631.h" #include @@ -66,7 +66,7 @@ bool isPlaybackon = false, isCaptureon = false; module_param(timesofbclk, int, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH); MODULE_PARM_DESC(timeofbclk, "relationship between bclk and fs"); - +static const DECLARE_TLV_DB_SCALE(dac_vol_tlv, -9435, 37, 0); static inline int rt5631_write(struct snd_soc_codec *codec, unsigned int reg, unsigned int val) { @@ -475,7 +475,7 @@ SOC_ENUM("MIC1 Boost", rt5631_enum[6]), SOC_ENUM("MIC2 Mode Control", rt5631_enum[4]), SOC_ENUM("MIC2 Boost", rt5631_enum[7]), SOC_ENUM("MONOIN Mode Control", rt5631_enum[5]), -SOC_DOUBLE("PCM Playback Volume", RT5631_STEREO_DAC_VOL_2, 8, 0, 255, 1), +SOC_DOUBLE_TLV("PCM Playback Volume", RT5631_STEREO_DAC_VOL_2, 8, 0, 255, 1, dac_vol_tlv), SOC_DOUBLE("PCM Playback Switch", RT5631_STEREO_DAC_VOL_1, 15, 7, 1, 1), SOC_DOUBLE("MONOIN_RX Capture Volume", RT5631_MONO_INPUT_VOL, 8, 0, 31, 1), SOC_DOUBLE("AXI Capture Volume", RT5631_AUX_IN_VOL, 8, 0, 31, 1), -- 2.34.1