Commit 53af408c authored by Steven Eckhoff's avatar Steven Eckhoff Committed by Mark Brown

ASoC: TSCS42xx: Add headphone auto switching

Add headphone auto switching controls
Signed-off-by: default avatarSteven Eckhoff <steven.eckhoff.opensource@gmail.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 19d996cc
...@@ -647,6 +647,12 @@ static const struct snd_kcontrol_new tscs42xx_snd_controls[] = { ...@@ -647,6 +647,12 @@ static const struct snd_kcontrol_new tscs42xx_snd_controls[] = {
/* Mic Bias */ /* Mic Bias */
SOC_SINGLE("Mic Bias Boost Switch", 0x71, 0x07, 1, 0), SOC_SINGLE("Mic Bias Boost Switch", 0x71, 0x07, 1, 0),
/* Headphone Auto Switching */
SOC_SINGLE("Headphone Auto Switching Switch",
R_CTL, FB_CTL_HPSWEN, 1, 0),
SOC_SINGLE("Headphone Detect Polarity Toggle Switch",
R_CTL, FB_CTL_HPSWPOL, 1, 0),
/* Coefficient Ram */ /* Coefficient Ram */
COEFF_RAM_CTL("Cascade1L BiQuad1", BIQUAD_SIZE, 0x00), COEFF_RAM_CTL("Cascade1L BiQuad1", BIQUAD_SIZE, 0x00),
COEFF_RAM_CTL("Cascade1L BiQuad2", BIQUAD_SIZE, 0x05), COEFF_RAM_CTL("Cascade1L BiQuad2", BIQUAD_SIZE, 0x05),
......
...@@ -34,6 +34,7 @@ enum { ...@@ -34,6 +34,7 @@ enum {
#define R_DACSR 0x19 #define R_DACSR 0x19
#define R_PWRM1 0x1A #define R_PWRM1 0x1A
#define R_PWRM2 0x1B #define R_PWRM2 0x1B
#define R_CTL 0x1C
#define R_CONFIG0 0x1F #define R_CONFIG0 0x1F
#define R_CONFIG1 0x20 #define R_CONFIG1 0x20
#define R_DMICCTL 0x24 #define R_DMICCTL 0x24
...@@ -1110,6 +1111,13 @@ enum { ...@@ -1110,6 +1111,13 @@ enum {
#define RV_PWRM2_VREF_DISABLE \ #define RV_PWRM2_VREF_DISABLE \
RV(FV_PWRM2_VREF_DISABLE, FB_PWRM2_VREF) RV(FV_PWRM2_VREF_DISABLE, FB_PWRM2_VREF)
/******************************
* R_CTL (0x1C) *
******************************/
/* Fiel Offsets */
#define FB_CTL_HPSWEN 7
#define FB_CTL_HPSWPOL 6
/****************************** /******************************
* R_CONFIG0 (0x1F) * * R_CONFIG0 (0x1F) *
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment