[alsa-devel] [PATCH 1/2] ASoC: rt5645: set RT5645_PRIV_INDEX as volatile
RT5645_PRIV_INDEX(0x6a) indicate the address of PR- registers. So, it should be volatile.
Signed-off-by: Bard Liao bardliao@realtek.com --- sound/soc/codecs/rt5645.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c index 97bf96e..9251720 100644 --- a/sound/soc/codecs/rt5645.c +++ b/sound/soc/codecs/rt5645.c @@ -441,6 +441,7 @@ static bool rt5645_volatile_register(struct device *dev, unsigned int reg)
switch (reg) { case RT5645_RESET: + case RT5645_PRIV_INDEX: case RT5645_PRIV_DATA: case RT5645_IN1_CTRL1: case RT5645_IN1_CTRL2:
This patch add an alsa control for DAC1 digital volume control function selection. The options are: 0: Gain update immediately 1: Gain update when a zero crossing 2: Gain update when a zero crossing with a soft ramp
Signed-off-by: Bard Liao bardliao@realtek.com --- sound/soc/codecs/rt5645.c | 4 ++++ sound/soc/codecs/rt5645.h | 3 +++ 2 files changed, 7 insertions(+)
diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c index 9251720..036628c 100644 --- a/sound/soc/codecs/rt5645.c +++ b/sound/soc/codecs/rt5645.c @@ -808,6 +808,10 @@ static const struct snd_kcontrol_new rt5645_snd_controls[] = { SOC_SINGLE("I2S2 Func Switch", RT5645_GPIO_CTRL1, RT5645_I2S2_SEL_SFT, 1, 1), RT5645_HWEQ("Speaker HWEQ"), + + /* Digiatl Soft Volume Control */ + SOC_SINGLE("DAC1 Digital Volume Control Func", + RT5645_PR_BASE, RT5645_DA1_ZDET_SFT, 3, 0), };
/** diff --git a/sound/soc/codecs/rt5645.h b/sound/soc/codecs/rt5645.h index 205e071..cfc5f97 100644 --- a/sound/soc/codecs/rt5645.h +++ b/sound/soc/codecs/rt5645.h @@ -2018,6 +2018,9 @@
/* Codec Private Register definition */ +/* DAC ADC Digital Volume (0x00) */ +#define RT5645_DA1_ZDET_SFT 6 + /* 3D Speaker Control (0x63) */ #define RT5645_3D_SPK_MASK (0x1 << 15) #define RT5645_3D_SPK_SFT 15
On Wed, Jul 06, 2016 at 09:55:15AM +0800, Bard Liao wrote:
This patch add an alsa control for DAC1 digital volume control function selection. The options are: 0: Gain update immediately 1: Gain update when a zero crossing 2: Gain update when a zero crossing with a soft ramp
This seems like it should be an enum?
The patch
ASoC: rt5645: set RT5645_PRIV_INDEX as volatile
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks, Mark
From 81467efcc88298ecd821c26fab04ce1b2c9d1b65 Mon Sep 17 00:00:00 2001
From: Bard Liao bardliao@realtek.com Date: Wed, 6 Jul 2016 09:55:14 +0800 Subject: [PATCH] ASoC: rt5645: set RT5645_PRIV_INDEX as volatile
RT5645_PRIV_INDEX(0x6a) indicate the address of PR- registers. So, it should be volatile.
Signed-off-by: Bard Liao bardliao@realtek.com Signed-off-by: Mark Brown broonie@kernel.org --- sound/soc/codecs/rt5645.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/sound/soc/codecs/rt5645.c b/sound/soc/codecs/rt5645.c index 3c6594da6c9c..c0438e4e045b 100644 --- a/sound/soc/codecs/rt5645.c +++ b/sound/soc/codecs/rt5645.c @@ -440,6 +440,7 @@ static bool rt5645_volatile_register(struct device *dev, unsigned int reg)
switch (reg) { case RT5645_RESET: + case RT5645_PRIV_INDEX: case RT5645_PRIV_DATA: case RT5645_IN1_CTRL1: case RT5645_IN1_CTRL2:
participants (2)
-
Bard Liao
-
Mark Brown