aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCharles Keepax <ckeepax@opensource.wolfsonmicro.com>2013-12-19 04:30:12 -0500
committerMark Brown <broonie@linaro.org>2013-12-19 05:20:31 -0500
commitfbedc8cbc3c40281cf52ed0e2e5998dea98e2992 (patch)
treed3ad602e04639b9f65dc08225cf264e1bd483bfb
parenta4c0d2735c66c2363100575324a2f7659fb1f684 (diff)
ASoC: wm5110: Add FSH for ISRCs
Currently, the driver only supports configuration of the lower sample rate (FSL) on the ISRCs. With the higher rate being fixed a SYSCLK, this patch adds support for configuring the higher sample rate (FSH). Signed-off-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com> Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r--sound/soc/codecs/arizona.c16
-rw-r--r--sound/soc/codecs/arizona.h1
-rw-r--r--sound/soc/codecs/wm5110.c3
3 files changed, 20 insertions, 0 deletions
diff --git a/sound/soc/codecs/arizona.c b/sound/soc/codecs/arizona.c
index 6bfd8031c0c9..56d3ff570ad4 100644
--- a/sound/soc/codecs/arizona.c
+++ b/sound/soc/codecs/arizona.c
@@ -498,6 +498,22 @@ const int arizona_rate_val[ARIZONA_RATE_ENUM_SIZE] = {
498EXPORT_SYMBOL_GPL(arizona_rate_val); 498EXPORT_SYMBOL_GPL(arizona_rate_val);
499 499
500 500
501const struct soc_enum arizona_isrc_fsh[] = {
502 SOC_VALUE_ENUM_SINGLE(ARIZONA_ISRC_1_CTRL_1,
503 ARIZONA_ISRC1_FSH_SHIFT, 0xf,
504 ARIZONA_RATE_ENUM_SIZE,
505 arizona_rate_text, arizona_rate_val),
506 SOC_VALUE_ENUM_SINGLE(ARIZONA_ISRC_2_CTRL_1,
507 ARIZONA_ISRC2_FSH_SHIFT, 0xf,
508 ARIZONA_RATE_ENUM_SIZE,
509 arizona_rate_text, arizona_rate_val),
510 SOC_VALUE_ENUM_SINGLE(ARIZONA_ISRC_3_CTRL_1,
511 ARIZONA_ISRC3_FSH_SHIFT, 0xf,
512 ARIZONA_RATE_ENUM_SIZE,
513 arizona_rate_text, arizona_rate_val),
514};
515EXPORT_SYMBOL_GPL(arizona_isrc_fsh);
516
501const struct soc_enum arizona_isrc_fsl[] = { 517const struct soc_enum arizona_isrc_fsl[] = {
502 SOC_VALUE_ENUM_SINGLE(ARIZONA_ISRC_1_CTRL_2, 518 SOC_VALUE_ENUM_SINGLE(ARIZONA_ISRC_1_CTRL_2,
503 ARIZONA_ISRC1_FSL_SHIFT, 0xf, 519 ARIZONA_ISRC1_FSL_SHIFT, 0xf,
diff --git a/sound/soc/codecs/arizona.h b/sound/soc/codecs/arizona.h
index 6641f3d64194..99a97c06d46a 100644
--- a/sound/soc/codecs/arizona.h
+++ b/sound/soc/codecs/arizona.h
@@ -186,6 +186,7 @@ extern const char *arizona_rate_text[ARIZONA_RATE_ENUM_SIZE];
186extern const int arizona_rate_val[ARIZONA_RATE_ENUM_SIZE]; 186extern const int arizona_rate_val[ARIZONA_RATE_ENUM_SIZE];
187 187
188extern const struct soc_enum arizona_isrc_fsl[]; 188extern const struct soc_enum arizona_isrc_fsl[];
189extern const struct soc_enum arizona_isrc_fsh[];
189 190
190extern const struct soc_enum arizona_in_vi_ramp; 191extern const struct soc_enum arizona_in_vi_ramp;
191extern const struct soc_enum arizona_in_vd_ramp; 192extern const struct soc_enum arizona_in_vd_ramp;
diff --git a/sound/soc/codecs/wm5110.c b/sound/soc/codecs/wm5110.c
index 3487ffa2e950..57be82261c2f 100644
--- a/sound/soc/codecs/wm5110.c
+++ b/sound/soc/codecs/wm5110.c
@@ -280,6 +280,9 @@ SOC_ENUM("LHPF4 Mode", arizona_lhpf4_mode),
280SOC_VALUE_ENUM("ISRC1 FSL", arizona_isrc_fsl[0]), 280SOC_VALUE_ENUM("ISRC1 FSL", arizona_isrc_fsl[0]),
281SOC_VALUE_ENUM("ISRC2 FSL", arizona_isrc_fsl[1]), 281SOC_VALUE_ENUM("ISRC2 FSL", arizona_isrc_fsl[1]),
282SOC_VALUE_ENUM("ISRC3 FSL", arizona_isrc_fsl[2]), 282SOC_VALUE_ENUM("ISRC3 FSL", arizona_isrc_fsl[2]),
283SOC_VALUE_ENUM("ISRC1 FSH", arizona_isrc_fsh[0]),
284SOC_VALUE_ENUM("ISRC2 FSH", arizona_isrc_fsh[1]),
285SOC_VALUE_ENUM("ISRC3 FSH", arizona_isrc_fsh[2]),
283 286
284ARIZONA_MIXER_CONTROLS("DSP1L", ARIZONA_DSP1LMIX_INPUT_1_SOURCE), 287ARIZONA_MIXER_CONTROLS("DSP1L", ARIZONA_DSP1LMIX_INPUT_1_SOURCE),
285ARIZONA_MIXER_CONTROLS("DSP1R", ARIZONA_DSP1RMIX_INPUT_1_SOURCE), 288ARIZONA_MIXER_CONTROLS("DSP1R", ARIZONA_DSP1RMIX_INPUT_1_SOURCE),