Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
1f2e7a90
Commit
1f2e7a90
authored
Feb 11, 2013
by
Mark Brown
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'asoc/topic/arizona' into asoc-next
parents
278d064b
c94aa30e
Changes
5
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
418 additions
and
114 deletions
+418
-114
include/linux/mfd/arizona/pdata.h
include/linux/mfd/arizona/pdata.h
+9
-0
sound/soc/codecs/arizona.c
sound/soc/codecs/arizona.c
+177
-55
sound/soc/codecs/arizona.h
sound/soc/codecs/arizona.h
+6
-2
sound/soc/codecs/wm5102.c
sound/soc/codecs/wm5102.c
+146
-26
sound/soc/codecs/wm5110.c
sound/soc/codecs/wm5110.c
+80
-31
No files found.
include/linux/mfd/arizona/pdata.h
View file @
1f2e7a90
...
...
@@ -62,6 +62,8 @@
#define ARIZONA_MAX_OUTPUT 6
#define ARIZONA_MAX_AIF 3
#define ARIZONA_HAP_ACT_ERM 0
#define ARIZONA_HAP_ACT_LRA 2
...
...
@@ -96,6 +98,13 @@ struct arizona_pdata {
/** Pin state for GPIO pins */
int
gpio_defaults
[
ARIZONA_MAX_GPIO
];
/**
* Maximum number of channels clocks will be generated for,
* useful for systems where and I2S bus with multiple data
* lines is mastered.
*/
int
max_channels_clocked
[
ARIZONA_MAX_AIF
];
/** GPIO for mic detection polarity */
int
micd_pol_gpio
;
...
...
sound/soc/codecs/arizona.c
View file @
1f2e7a90
...
...
@@ -141,6 +141,30 @@ const char *arizona_mixer_texts[ARIZONA_NUM_MIXER_INPUTS] = {
"ASRC1R"
,
"ASRC2L"
,
"ASRC2R"
,
"ISRC1INT1"
,
"ISRC1INT2"
,
"ISRC1INT3"
,
"ISRC1INT4"
,
"ISRC1DEC1"
,
"ISRC1DEC2"
,
"ISRC1DEC3"
,
"ISRC1DEC4"
,
"ISRC2INT1"
,
"ISRC2INT2"
,
"ISRC2INT3"
,
"ISRC2INT4"
,
"ISRC2DEC1"
,
"ISRC2DEC2"
,
"ISRC2DEC3"
,
"ISRC2DEC4"
,
"ISRC3INT1"
,
"ISRC3INT2"
,
"ISRC3INT3"
,
"ISRC3INT4"
,
"ISRC3DEC1"
,
"ISRC3DEC2"
,
"ISRC3DEC3"
,
"ISRC3DEC4"
,
};
EXPORT_SYMBOL_GPL
(
arizona_mixer_texts
);
...
...
@@ -220,6 +244,30 @@ int arizona_mixer_values[ARIZONA_NUM_MIXER_INPUTS] = {
0x91
,
0x92
,
0x93
,
0xa0
,
/* ISRC1INT1 */
0xa1
,
0xa2
,
0xa3
,
0xa4
,
/* ISRC1DEC1 */
0xa5
,
0xa6
,
0xa7
,
0xa8
,
/* ISRC2DEC1 */
0xa9
,
0xaa
,
0xab
,
0xac
,
/* ISRC2INT1 */
0xad
,
0xae
,
0xaf
,
0xb0
,
/* ISRC3DEC1 */
0xb1
,
0xb2
,
0xb3
,
0xb4
,
/* ISRC3INT1 */
0xb5
,
0xb6
,
0xb7
,
};
EXPORT_SYMBOL_GPL
(
arizona_mixer_values
);
...
...
@@ -275,6 +323,15 @@ const struct soc_enum arizona_lhpf4_mode =
arizona_lhpf_mode_text
);
EXPORT_SYMBOL_GPL
(
arizona_lhpf4_mode
);
static
const
char
*
arizona_ng_hold_text
[]
=
{
"30ms"
,
"120ms"
,
"250ms"
,
"500ms"
,
};
const
struct
soc_enum
arizona_ng_hold
=
SOC_ENUM_SINGLE
(
ARIZONA_NOISE_GATE_CONTROL
,
ARIZONA_NGATE_HOLD_SHIFT
,
4
,
arizona_ng_hold_text
);
EXPORT_SYMBOL_GPL
(
arizona_ng_hold
);
int
arizona_in_ev
(
struct
snd_soc_dapm_widget
*
w
,
struct
snd_kcontrol
*
kcontrol
,
int
event
)
{
...
...
@@ -417,6 +474,10 @@ int arizona_set_sysclk(struct snd_soc_codec *codec, int clk_id,
case
147456000
:
val
|=
6
<<
ARIZONA_SYSCLK_FREQ_SHIFT
;
break
;
case
0
:
dev_dbg
(
arizona
->
dev
,
"%s cleared
\n
"
,
name
);
*
clk
=
freq
;
return
0
;
default:
return
-
EINVAL
;
}
...
...
@@ -635,6 +696,9 @@ static int arizona_startup(struct snd_pcm_substream *substream,
return
0
;
}
if
(
base_rate
==
0
)
return
0
;
if
(
base_rate
%
8000
)
constraint
=
&
arizona_44k1_constraint
;
else
...
...
@@ -645,7 +709,7 @@ static int arizona_startup(struct snd_pcm_substream *substream,
constraint
);
}
static
int
arizona_hw_params
(
struct
snd_pcm_substream
*
substream
,
static
int
arizona_hw_params
_rate
(
struct
snd_pcm_substream
*
substream
,
struct
snd_pcm_hw_params
*
params
,
struct
snd_soc_dai
*
dai
)
{
...
...
@@ -653,28 +717,12 @@ static int arizona_hw_params(struct snd_pcm_substream *substream,
struct
arizona_priv
*
priv
=
snd_soc_codec_get_drvdata
(
codec
);
struct
arizona_dai_priv
*
dai_priv
=
&
priv
->
dai
[
dai
->
id
-
1
];
int
base
=
dai
->
driver
->
base
;
const
int
*
rates
;
int
i
;
int
bclk
,
lrclk
,
wl
,
frame
,
sr_val
;
if
(
params_rate
(
params
)
%
8000
)
rates
=
&
arizona_44k1_bclk_rates
[
0
];
else
rates
=
&
arizona_48k_bclk_rates
[
0
];
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
arizona_44k1_bclk_rates
);
i
++
)
{
if
(
rates
[
i
]
>=
snd_soc_params_to_bclk
(
params
)
&&
rates
[
i
]
%
params_rate
(
params
)
==
0
)
{
bclk
=
i
;
break
;
}
}
if
(
i
==
ARRAY_SIZE
(
arizona_44k1_bclk_rates
))
{
arizona_aif_err
(
dai
,
"Unsupported sample rate %dHz
\n
"
,
params_rate
(
params
));
return
-
EINVAL
;
}
int
i
,
sr_val
;
/*
* We will need to be more flexible than this in future,
* currently we use a single sample rate for SYSCLK.
*/
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
arizona_sr_vals
);
i
++
)
if
(
arizona_sr_vals
[
i
]
==
params_rate
(
params
))
break
;
...
...
@@ -685,28 +733,18 @@ static int arizona_hw_params(struct snd_pcm_substream *substream,
}
sr_val
=
i
;
lrclk
=
rates
[
bclk
]
/
params_rate
(
params
);
arizona_aif_dbg
(
dai
,
"BCLK %dHz LRCLK %dHz
\n
"
,
rates
[
bclk
],
rates
[
bclk
]
/
lrclk
);
wl
=
snd_pcm_format_width
(
params_format
(
params
));
frame
=
wl
<<
ARIZONA_AIF1TX_WL_SHIFT
|
wl
;
/*
* We will need to be more flexible than this in future,
* currently we use a single sample rate for SYSCLK.
*/
switch
(
dai_priv
->
clk
)
{
case
ARIZONA_CLK_SYSCLK
:
snd_soc_update_bits
(
codec
,
ARIZONA_SAMPLE_RATE_1
,
ARIZONA_SAMPLE_RATE_1_MASK
,
sr_val
);
if
(
base
)
snd_soc_update_bits
(
codec
,
base
+
ARIZONA_AIF_RATE_CTRL
,
ARIZONA_AIF1_RATE_MASK
,
0
);
break
;
case
ARIZONA_CLK_ASYNCCLK
:
snd_soc_update_bits
(
codec
,
ARIZONA_ASYNC_SAMPLE_RATE_1
,
ARIZONA_ASYNC_SAMPLE_RATE_MASK
,
sr_val
);
if
(
base
)
snd_soc_update_bits
(
codec
,
base
+
ARIZONA_AIF_RATE_CTRL
,
ARIZONA_AIF1_RATE_MASK
,
8
<<
ARIZONA_AIF1_RATE_SHIFT
);
...
...
@@ -716,6 +754,59 @@ static int arizona_hw_params(struct snd_pcm_substream *substream,
return
-
EINVAL
;
}
return
0
;
}
static
int
arizona_hw_params
(
struct
snd_pcm_substream
*
substream
,
struct
snd_pcm_hw_params
*
params
,
struct
snd_soc_dai
*
dai
)
{
struct
snd_soc_codec
*
codec
=
dai
->
codec
;
struct
arizona_priv
*
priv
=
snd_soc_codec_get_drvdata
(
codec
);
struct
arizona
*
arizona
=
priv
->
arizona
;
int
base
=
dai
->
driver
->
base
;
const
int
*
rates
;
int
i
,
ret
;
int
chan_limit
=
arizona
->
pdata
.
max_channels_clocked
[
dai
->
id
-
1
];
int
bclk
,
lrclk
,
wl
,
frame
,
bclk_target
;
if
(
params_rate
(
params
)
%
8000
)
rates
=
&
arizona_44k1_bclk_rates
[
0
];
else
rates
=
&
arizona_48k_bclk_rates
[
0
];
bclk_target
=
snd_soc_params_to_bclk
(
params
);
if
(
chan_limit
&&
chan_limit
<
params_channels
(
params
))
{
arizona_aif_dbg
(
dai
,
"Limiting to %d channels
\n
"
,
chan_limit
);
bclk_target
/=
params_channels
(
params
);
bclk_target
*=
chan_limit
;
}
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
arizona_44k1_bclk_rates
);
i
++
)
{
if
(
rates
[
i
]
>=
bclk_target
&&
rates
[
i
]
%
params_rate
(
params
)
==
0
)
{
bclk
=
i
;
break
;
}
}
if
(
i
==
ARRAY_SIZE
(
arizona_44k1_bclk_rates
))
{
arizona_aif_err
(
dai
,
"Unsupported sample rate %dHz
\n
"
,
params_rate
(
params
));
return
-
EINVAL
;
}
lrclk
=
rates
[
bclk
]
/
params_rate
(
params
);
arizona_aif_dbg
(
dai
,
"BCLK %dHz LRCLK %dHz
\n
"
,
rates
[
bclk
],
rates
[
bclk
]
/
lrclk
);
wl
=
snd_pcm_format_width
(
params_format
(
params
));
frame
=
wl
<<
ARIZONA_AIF1TX_WL_SHIFT
|
wl
;
ret
=
arizona_hw_params_rate
(
substream
,
params
,
dai
);
if
(
ret
!=
0
)
return
ret
;
snd_soc_update_bits
(
codec
,
base
+
ARIZONA_AIF_BCLK_CTRL
,
ARIZONA_AIF1_BCLK_FREQ_MASK
,
bclk
);
snd_soc_update_bits
(
codec
,
base
+
ARIZONA_AIF_TX_BCLK_RATE
,
...
...
@@ -789,11 +880,27 @@ static int arizona_dai_set_sysclk(struct snd_soc_dai *dai,
return
snd_soc_dapm_sync
(
&
codec
->
dapm
);
}
static
int
arizona_set_tristate
(
struct
snd_soc_dai
*
dai
,
int
tristate
)
{
struct
snd_soc_codec
*
codec
=
dai
->
codec
;
int
base
=
dai
->
driver
->
base
;
unsigned
int
reg
;
if
(
tristate
)
reg
=
ARIZONA_AIF1_TRI
;
else
reg
=
0
;
return
snd_soc_update_bits
(
codec
,
base
+
ARIZONA_AIF_RATE_CTRL
,
ARIZONA_AIF1_TRI
,
reg
);
}
const
struct
snd_soc_dai_ops
arizona_dai_ops
=
{
.
startup
=
arizona_startup
,
.
set_fmt
=
arizona_set_fmt
,
.
hw_params
=
arizona_hw_params
,
.
set_sysclk
=
arizona_dai_set_sysclk
,
.
set_tristate
=
arizona_set_tristate
,
};
EXPORT_SYMBOL_GPL
(
arizona_dai_ops
);
...
...
@@ -807,17 +914,6 @@ int arizona_init_dai(struct arizona_priv *priv, int id)
}
EXPORT_SYMBOL_GPL
(
arizona_init_dai
);
static
irqreturn_t
arizona_fll_lock
(
int
irq
,
void
*
data
)
{
struct
arizona_fll
*
fll
=
data
;
arizona_fll_dbg
(
fll
,
"Lock status changed
\n
"
);
complete
(
&
fll
->
lock
);
return
IRQ_HANDLED
;
}
static
irqreturn_t
arizona_fll_clock_ok
(
int
irq
,
void
*
data
)
{
struct
arizona_fll
*
fll
=
data
;
...
...
@@ -1066,7 +1162,6 @@ int arizona_init_fll(struct arizona *arizona, int id, int base, int lock_irq,
{
int
ret
;
init_completion
(
&
fll
->
lock
);
init_completion
(
&
fll
->
ok
);
fll
->
id
=
id
;
...
...
@@ -1077,13 +1172,6 @@ int arizona_init_fll(struct arizona *arizona, int id, int base, int lock_irq,
snprintf
(
fll
->
clock_ok_name
,
sizeof
(
fll
->
clock_ok_name
),
"FLL%d clock OK"
,
id
);
ret
=
arizona_request_irq
(
arizona
,
lock_irq
,
fll
->
lock_name
,
arizona_fll_lock
,
fll
);
if
(
ret
!=
0
)
{
dev_err
(
arizona
->
dev
,
"Failed to get FLL%d lock IRQ: %d
\n
"
,
id
,
ret
);
}
ret
=
arizona_request_irq
(
arizona
,
ok_irq
,
fll
->
clock_ok_name
,
arizona_fll_clock_ok
,
fll
);
if
(
ret
!=
0
)
{
...
...
@@ -1098,6 +1186,40 @@ int arizona_init_fll(struct arizona *arizona, int id, int base, int lock_irq,
}
EXPORT_SYMBOL_GPL
(
arizona_init_fll
);
/**
* arizona_set_output_mode - Set the mode of the specified output
*
* @codec: Device to configure
* @output: Output number
* @diff: True to set the output to differential mode
*
* Some systems use external analogue switches to connect more
* analogue devices to the CODEC than are supported by the device. In
* some systems this requires changing the switched output from single
* ended to differential mode dynamically at runtime, an operation
* supported using this function.
*
* Most systems have a single static configuration and should use
* platform data instead.
*/
int
arizona_set_output_mode
(
struct
snd_soc_codec
*
codec
,
int
output
,
bool
diff
)
{
unsigned
int
reg
,
val
;
if
(
output
<
1
||
output
>
6
)
return
-
EINVAL
;
reg
=
ARIZONA_OUTPUT_PATH_CONFIG_1L
+
(
output
-
1
)
*
8
;
if
(
diff
)
val
=
ARIZONA_OUT1_MONO
;
else
val
=
0
;
return
snd_soc_update_bits
(
codec
,
reg
,
ARIZONA_OUT1_MONO
,
val
);
}
EXPORT_SYMBOL_GPL
(
arizona_set_output_mode
);
MODULE_DESCRIPTION
(
"ASoC Wolfson Arizona class device support"
);
MODULE_AUTHOR
(
"Mark Brown <broonie@opensource.wolfsonmicro.com>"
);
MODULE_LICENSE
(
"GPL"
);
sound/soc/codecs/arizona.h
View file @
1f2e7a90
...
...
@@ -66,7 +66,7 @@ struct arizona_priv {
struct
arizona_dai_priv
dai
[
ARIZONA_MAX_DAI
];
};
#define ARIZONA_NUM_MIXER_INPUTS
75
#define ARIZONA_NUM_MIXER_INPUTS
99
extern
const
unsigned
int
arizona_mixer_tlv
[];
extern
const
char
*
arizona_mixer_texts
[
ARIZONA_NUM_MIXER_INPUTS
];
...
...
@@ -176,6 +176,8 @@ extern const struct soc_enum arizona_lhpf2_mode;
extern
const
struct
soc_enum
arizona_lhpf3_mode
;
extern
const
struct
soc_enum
arizona_lhpf4_mode
;
extern
const
struct
soc_enum
arizona_ng_hold
;
extern
int
arizona_in_ev
(
struct
snd_soc_dapm_widget
*
w
,
struct
snd_kcontrol
*
kcontrol
,
int
event
);
...
...
@@ -195,7 +197,6 @@ struct arizona_fll {
int
id
;
unsigned
int
base
;
unsigned
int
vco_mult
;
struct
completion
lock
;
struct
completion
ok
;
unsigned
int
fref
;
unsigned
int
fout
;
...
...
@@ -211,4 +212,7 @@ extern int arizona_set_fll(struct arizona_fll *fll, int source,
extern
int
arizona_init_dai
(
struct
arizona_priv
*
priv
,
int
dai
);
int
arizona_set_output_mode
(
struct
snd_soc_codec
*
codec
,
int
output
,
bool
diff
);
#endif
sound/soc/codecs/wm5102.c
View file @
1f2e7a90
This diff is collapsed.
Click to expand it.
sound/soc/codecs/wm5110.c
View file @
1f2e7a90
...
...
@@ -41,6 +41,21 @@ static DECLARE_TLV_DB_SCALE(ana_tlv, 0, 100, 0);
static
DECLARE_TLV_DB_SCALE
(
eq_tlv
,
-
1200
,
100
,
0
);
static
DECLARE_TLV_DB_SCALE
(
digital_tlv
,
-
6400
,
50
,
0
);
static
DECLARE_TLV_DB_SCALE
(
noise_tlv
,
0
,
600
,
0
);
static
DECLARE_TLV_DB_SCALE
(
ng_tlv
,
-
10200
,
600
,
0
);
#define WM5110_NG_SRC(name, base) \
SOC_SINGLE(name " NG HPOUT1L Switch", base, 0, 1, 0), \
SOC_SINGLE(name " NG HPOUT1R Switch", base, 1, 1, 0), \
SOC_SINGLE(name " NG HPOUT2L Switch", base, 2, 1, 0), \
SOC_SINGLE(name " NG HPOUT2R Switch", base, 3, 1, 0), \
SOC_SINGLE(name " NG HPOUT3L Switch", base, 4, 1, 0), \
SOC_SINGLE(name " NG HPOUT3R Switch", base, 5, 1, 0), \
SOC_SINGLE(name " NG SPKOUTL Switch", base, 6, 1, 0), \
SOC_SINGLE(name " NG SPKOUTR Switch", base, 7, 1, 0), \
SOC_SINGLE(name " NG SPKDAT1L Switch", base, 8, 1, 0), \
SOC_SINGLE(name " NG SPKDAT1R Switch", base, 9, 1, 0), \
SOC_SINGLE(name " NG SPKDAT2L Switch", base, 10, 1, 0), \
SOC_SINGLE(name " NG SPKDAT2R Switch", base, 11, 1, 0)
static
const
struct
snd_kcontrol_new
wm5110_snd_controls
[]
=
{
SOC_SINGLE
(
"IN1 High Performance Switch"
,
ARIZONA_IN1L_CONTROL
,
...
...
@@ -52,37 +67,52 @@ SOC_SINGLE("IN3 High Performance Switch", ARIZONA_IN3L_CONTROL,
SOC_SINGLE
(
"IN4 High Performance Switch"
,
ARIZONA_IN4L_CONTROL
,
ARIZONA_IN4_OSR_SHIFT
,
1
,
0
),
SOC_DOUBLE_R_RANGE_TLV
(
"IN1 Volume"
,
ARIZONA_IN1L_CONTROL
,
ARIZONA_IN1R_CONTROL
,
SOC_SINGLE_RANGE_TLV
(
"IN1L Volume"
,
ARIZONA_IN1L_CONTROL
,
ARIZONA_IN1L_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_DOUBLE_R_RANGE_TLV
(
"IN2 Volume"
,
ARIZONA_IN2L_CONTROL
,
ARIZONA_IN2R_CONTROL
,
SOC_SINGLE_RANGE_TLV
(
"IN1R Volume"
,
ARIZONA_IN1R_CONTROL
,
ARIZONA_IN1R_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_SINGLE_RANGE_TLV
(
"IN2L Volume"
,
ARIZONA_IN2L_CONTROL
,
ARIZONA_IN2L_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_DOUBLE_R_RANGE_TLV
(
"IN3 Volume"
,
ARIZONA_IN3L_CONTROL
,
ARIZONA_IN3R_CONTROL
,
SOC_SINGLE_RANGE_TLV
(
"IN2R Volume"
,
ARIZONA_IN2R_CONTROL
,
ARIZONA_IN2R_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_SINGLE_RANGE_TLV
(
"IN3L Volume"
,
ARIZONA_IN3L_CONTROL
,
ARIZONA_IN3L_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_DOUBLE_R
(
"IN1 Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_1L
,
ARIZONA_ADC_DIGITAL_VOLUME_1R
,
ARIZONA_IN1L_MUTE_SHIFT
,
1
,
1
),
SOC_DOUBLE_R
(
"IN2 Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_2L
,
ARIZONA_ADC_DIGITAL_VOLUME_2R
,
ARIZONA_IN2L_MUTE_SHIFT
,
1
,
1
),
SOC_DOUBLE_R
(
"IN3 Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_3L
,
ARIZONA_ADC_DIGITAL_VOLUME_3R
,
ARIZONA_IN3L_MUTE_SHIFT
,
1
,
1
),
SOC_DOUBLE_R
(
"IN4 Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_4L
,
ARIZONA_ADC_DIGITAL_VOLUME_4R
,
ARIZONA_IN4L_MUTE_SHIFT
,
1
,
1
),
SOC_DOUBLE_R_TLV
(
"IN1 Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_1L
,
ARIZONA_ADC_DIGITAL_VOLUME_1R
,
ARIZONA_IN1L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_DOUBLE_R_TLV
(
"IN2 Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_2L
,
ARIZONA_ADC_DIGITAL_VOLUME_2R
,
ARIZONA_IN2L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_DOUBLE_R_TLV
(
"IN3 Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_3L
,
ARIZONA_ADC_DIGITAL_VOLUME_3R
,
ARIZONA_IN3L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_DOUBLE_R_TLV
(
"IN4 Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_4L
,
ARIZONA_ADC_DIGITAL_VOLUME_4R
,
ARIZONA_IN4L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_RANGE_TLV
(
"IN3R Volume"
,
ARIZONA_IN3R_CONTROL
,
ARIZONA_IN3R_PGA_VOL_SHIFT
,
0x40
,
0x5f
,
0
,
ana_tlv
),
SOC_SINGLE
(
"IN1L Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_1L
,
ARIZONA_IN1L_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN1R Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_1R
,
ARIZONA_IN1R_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN2L Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_2L
,
ARIZONA_IN2L_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN2R Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_2R
,
ARIZONA_IN2R_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN3L Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_3L
,
ARIZONA_IN3L_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN3R Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_3R
,
ARIZONA_IN3R_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN4L Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_4L
,
ARIZONA_IN4L_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE
(
"IN4R Digital Switch"
,
ARIZONA_ADC_DIGITAL_VOLUME_4R
,
ARIZONA_IN4R_MUTE_SHIFT
,
1
,
1
),
SOC_SINGLE_TLV
(
"IN1L Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_1L
,
ARIZONA_IN1L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN1R Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_1R
,
ARIZONA_IN1R_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN2L Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_2L
,
ARIZONA_IN2L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN2R Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_2R
,
ARIZONA_IN2R_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN3L Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_3L
,
ARIZONA_IN3L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN3R Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_3R
,
ARIZONA_IN3R_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN4L Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_4L
,
ARIZONA_IN4L_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_SINGLE_TLV
(
"IN4R Digital Volume"
,
ARIZONA_ADC_DIGITAL_VOLUME_4R
,
ARIZONA_IN4R_DIG_VOL_SHIFT
,
0xbf
,
0
,
digital_tlv
),
SOC_ENUM
(
"Input Ramp Up"
,
arizona_in_vi_ramp
),
SOC_ENUM
(
"Input Ramp Down"
,
arizona_in_vd_ramp
),
...
...
@@ -263,6 +293,25 @@ SOC_DOUBLE("SPKDAT2 Switch", ARIZONA_PDM_SPK2_CTRL_1, ARIZONA_SPK2L_MUTE_SHIFT,
SOC_ENUM
(
"Output Ramp Up"
,
arizona_out_vi_ramp
),
SOC_ENUM
(
"Output Ramp Down"
,
arizona_out_vd_ramp
),
SOC_SINGLE
(
"Noise Gate Switch"
,
ARIZONA_NOISE_GATE_CONTROL
,
ARIZONA_NGATE_ENA_SHIFT
,
1
,
0
),
SOC_SINGLE_TLV
(
"Noise Gate Threshold Volume"
,
ARIZONA_NOISE_GATE_CONTROL
,
ARIZONA_NGATE_THR_SHIFT
,
7
,
1
,
ng_tlv
),
SOC_ENUM
(
"Noise Gate Hold"
,
arizona_ng_hold
),
WM5110_NG_SRC
(
"HPOUT1L"
,
ARIZONA_NOISE_GATE_SELECT_1L
),
WM5110_NG_SRC
(
"HPOUT1R"
,
ARIZONA_NOISE_GATE_SELECT_1R
),
WM5110_NG_SRC
(
"HPOUT2L"
,
ARIZONA_NOISE_GATE_SELECT_2L
),
WM5110_NG_SRC
(
"HPOUT2R"
,
ARIZONA_NOISE_GATE_SELECT_2R
),
WM5110_NG_SRC
(
"HPOUT3L"
,
ARIZONA_NOISE_GATE_SELECT_3L
),
WM5110_NG_SRC
(
"HPOUT3R"
,
ARIZONA_NOISE_GATE_SELECT_3R
),
WM5110_NG_SRC
(
"SPKOUTL"
,
ARIZONA_NOISE_GATE_SELECT_4L
),
WM5110_NG_SRC
(
"SPKOUTR"
,
ARIZONA_NOISE_GATE_SELECT_4R
),
WM5110_NG_SRC
(
"SPKDAT1L"
,
ARIZONA_NOISE_GATE_SELECT_5L
),
WM5110_NG_SRC
(
"SPKDAT1R"
,
ARIZONA_NOISE_GATE_SELECT_5R
),
WM5110_NG_SRC
(
"SPKDAT2L"
,
ARIZONA_NOISE_GATE_SELECT_6L
),
WM5110_NG_SRC
(
"SPKDAT2R"
,
ARIZONA_NOISE_GATE_SELECT_6R
),
ARIZONA_MIXER_CONTROLS
(
"AIF1TX1"
,
ARIZONA_AIF1TX1MIX_INPUT_1_SOURCE
),
ARIZONA_MIXER_CONTROLS
(
"AIF1TX2"
,
ARIZONA_AIF1TX2MIX_INPUT_1_SOURCE
),
ARIZONA_MIXER_CONTROLS
(
"AIF1TX3"
,
ARIZONA_AIF1TX3MIX_INPUT_1_SOURCE
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment