diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-05-17 08:29:05 -0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-05-20 12:27:59 -0400 |
commit | d217f9055631fb910f4f2e09ccf6446d93ff6533 (patch) | |
tree | d020cba2b117f916ecf8587e13e58141a8188176 /sound/soc/codecs/wm5110.c | |
parent | 1804aff60d3bfe34223744ec8c301699bc0b0407 (diff) |
ASoC: wm5110: Stub hookup for Slimbus interface
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs/wm5110.c')
-rw-r--r-- | sound/soc/codecs/wm5110.c | 179 |
1 files changed, 179 insertions, 0 deletions
diff --git a/sound/soc/codecs/wm5110.c b/sound/soc/codecs/wm5110.c index 731884e04776..f53062f8c42e 100644 --- a/sound/soc/codecs/wm5110.c +++ b/sound/soc/codecs/wm5110.c | |||
@@ -309,6 +309,15 @@ ARIZONA_MIXER_CONTROLS("AIF2TX2", ARIZONA_AIF2TX2MIX_INPUT_1_SOURCE), | |||
309 | 309 | ||
310 | ARIZONA_MIXER_CONTROLS("AIF3TX1", ARIZONA_AIF3TX1MIX_INPUT_1_SOURCE), | 310 | ARIZONA_MIXER_CONTROLS("AIF3TX1", ARIZONA_AIF3TX1MIX_INPUT_1_SOURCE), |
311 | ARIZONA_MIXER_CONTROLS("AIF3TX2", ARIZONA_AIF3TX2MIX_INPUT_1_SOURCE), | 311 | ARIZONA_MIXER_CONTROLS("AIF3TX2", ARIZONA_AIF3TX2MIX_INPUT_1_SOURCE), |
312 | |||
313 | ARIZONA_MIXER_CONTROLS("SLIMTX1", ARIZONA_SLIMTX1MIX_INPUT_1_SOURCE), | ||
314 | ARIZONA_MIXER_CONTROLS("SLIMTX2", ARIZONA_SLIMTX2MIX_INPUT_1_SOURCE), | ||
315 | ARIZONA_MIXER_CONTROLS("SLIMTX3", ARIZONA_SLIMTX3MIX_INPUT_1_SOURCE), | ||
316 | ARIZONA_MIXER_CONTROLS("SLIMTX4", ARIZONA_SLIMTX4MIX_INPUT_1_SOURCE), | ||
317 | ARIZONA_MIXER_CONTROLS("SLIMTX5", ARIZONA_SLIMTX5MIX_INPUT_1_SOURCE), | ||
318 | ARIZONA_MIXER_CONTROLS("SLIMTX6", ARIZONA_SLIMTX6MIX_INPUT_1_SOURCE), | ||
319 | ARIZONA_MIXER_CONTROLS("SLIMTX7", ARIZONA_SLIMTX7MIX_INPUT_1_SOURCE), | ||
320 | ARIZONA_MIXER_CONTROLS("SLIMTX8", ARIZONA_SLIMTX8MIX_INPUT_1_SOURCE), | ||
312 | }; | 321 | }; |
313 | 322 | ||
314 | ARIZONA_MIXER_ENUMS(EQ1, ARIZONA_EQ1MIX_INPUT_1_SOURCE); | 323 | ARIZONA_MIXER_ENUMS(EQ1, ARIZONA_EQ1MIX_INPUT_1_SOURCE); |
@@ -360,6 +369,15 @@ ARIZONA_MIXER_ENUMS(AIF2TX2, ARIZONA_AIF2TX2MIX_INPUT_1_SOURCE); | |||
360 | ARIZONA_MIXER_ENUMS(AIF3TX1, ARIZONA_AIF3TX1MIX_INPUT_1_SOURCE); | 369 | ARIZONA_MIXER_ENUMS(AIF3TX1, ARIZONA_AIF3TX1MIX_INPUT_1_SOURCE); |
361 | ARIZONA_MIXER_ENUMS(AIF3TX2, ARIZONA_AIF3TX2MIX_INPUT_1_SOURCE); | 370 | ARIZONA_MIXER_ENUMS(AIF3TX2, ARIZONA_AIF3TX2MIX_INPUT_1_SOURCE); |
362 | 371 | ||
372 | ARIZONA_MIXER_ENUMS(SLIMTX1, ARIZONA_SLIMTX1MIX_INPUT_1_SOURCE); | ||
373 | ARIZONA_MIXER_ENUMS(SLIMTX2, ARIZONA_SLIMTX2MIX_INPUT_1_SOURCE); | ||
374 | ARIZONA_MIXER_ENUMS(SLIMTX3, ARIZONA_SLIMTX3MIX_INPUT_1_SOURCE); | ||
375 | ARIZONA_MIXER_ENUMS(SLIMTX4, ARIZONA_SLIMTX4MIX_INPUT_1_SOURCE); | ||
376 | ARIZONA_MIXER_ENUMS(SLIMTX5, ARIZONA_SLIMTX5MIX_INPUT_1_SOURCE); | ||
377 | ARIZONA_MIXER_ENUMS(SLIMTX6, ARIZONA_SLIMTX6MIX_INPUT_1_SOURCE); | ||
378 | ARIZONA_MIXER_ENUMS(SLIMTX7, ARIZONA_SLIMTX7MIX_INPUT_1_SOURCE); | ||
379 | ARIZONA_MIXER_ENUMS(SLIMTX8, ARIZONA_SLIMTX8MIX_INPUT_1_SOURCE); | ||
380 | |||
363 | ARIZONA_MUX_ENUMS(ASRC1L, ARIZONA_ASRC1LMIX_INPUT_1_SOURCE); | 381 | ARIZONA_MUX_ENUMS(ASRC1L, ARIZONA_ASRC1LMIX_INPUT_1_SOURCE); |
364 | ARIZONA_MUX_ENUMS(ASRC1R, ARIZONA_ASRC1RMIX_INPUT_1_SOURCE); | 382 | ARIZONA_MUX_ENUMS(ASRC1R, ARIZONA_ASRC1RMIX_INPUT_1_SOURCE); |
365 | ARIZONA_MUX_ENUMS(ASRC2L, ARIZONA_ASRC2LMIX_INPUT_1_SOURCE); | 383 | ARIZONA_MUX_ENUMS(ASRC2L, ARIZONA_ASRC2LMIX_INPUT_1_SOURCE); |
@@ -549,6 +567,56 @@ SND_SOC_DAPM_AIF_IN("AIF2RX1", NULL, 0, | |||
549 | SND_SOC_DAPM_AIF_IN("AIF2RX2", NULL, 0, | 567 | SND_SOC_DAPM_AIF_IN("AIF2RX2", NULL, 0, |
550 | ARIZONA_AIF2_RX_ENABLES, ARIZONA_AIF2RX2_ENA_SHIFT, 0), | 568 | ARIZONA_AIF2_RX_ENABLES, ARIZONA_AIF2RX2_ENA_SHIFT, 0), |
551 | 569 | ||
570 | SND_SOC_DAPM_AIF_IN("SLIMRX1", NULL, 0, | ||
571 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
572 | ARIZONA_SLIMRX1_ENA_SHIFT, 0), | ||
573 | SND_SOC_DAPM_AIF_IN("SLIMRX2", NULL, 0, | ||
574 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
575 | ARIZONA_SLIMRX2_ENA_SHIFT, 0), | ||
576 | SND_SOC_DAPM_AIF_IN("SLIMRX3", NULL, 0, | ||
577 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
578 | ARIZONA_SLIMRX3_ENA_SHIFT, 0), | ||
579 | SND_SOC_DAPM_AIF_IN("SLIMRX4", NULL, 0, | ||
580 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
581 | ARIZONA_SLIMRX4_ENA_SHIFT, 0), | ||
582 | SND_SOC_DAPM_AIF_IN("SLIMRX5", NULL, 0, | ||
583 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
584 | ARIZONA_SLIMRX5_ENA_SHIFT, 0), | ||
585 | SND_SOC_DAPM_AIF_IN("SLIMRX6", NULL, 0, | ||
586 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
587 | ARIZONA_SLIMRX6_ENA_SHIFT, 0), | ||
588 | SND_SOC_DAPM_AIF_IN("SLIMRX7", NULL, 0, | ||
589 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
590 | ARIZONA_SLIMRX7_ENA_SHIFT, 0), | ||
591 | SND_SOC_DAPM_AIF_IN("SLIMRX8", NULL, 0, | ||
592 | ARIZONA_SLIMBUS_RX_CHANNEL_ENABLE, | ||
593 | ARIZONA_SLIMRX8_ENA_SHIFT, 0), | ||
594 | |||
595 | SND_SOC_DAPM_AIF_OUT("SLIMTX1", NULL, 0, | ||
596 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
597 | ARIZONA_SLIMTX1_ENA_SHIFT, 0), | ||
598 | SND_SOC_DAPM_AIF_OUT("SLIMTX2", NULL, 0, | ||
599 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
600 | ARIZONA_SLIMTX2_ENA_SHIFT, 0), | ||
601 | SND_SOC_DAPM_AIF_OUT("SLIMTX3", NULL, 0, | ||
602 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
603 | ARIZONA_SLIMTX3_ENA_SHIFT, 0), | ||
604 | SND_SOC_DAPM_AIF_OUT("SLIMTX4", NULL, 0, | ||
605 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
606 | ARIZONA_SLIMTX4_ENA_SHIFT, 0), | ||
607 | SND_SOC_DAPM_AIF_OUT("SLIMTX5", NULL, 0, | ||
608 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
609 | ARIZONA_SLIMTX5_ENA_SHIFT, 0), | ||
610 | SND_SOC_DAPM_AIF_OUT("SLIMTX6", NULL, 0, | ||
611 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
612 | ARIZONA_SLIMTX6_ENA_SHIFT, 0), | ||
613 | SND_SOC_DAPM_AIF_OUT("SLIMTX7", NULL, 0, | ||
614 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
615 | ARIZONA_SLIMTX7_ENA_SHIFT, 0), | ||
616 | SND_SOC_DAPM_AIF_OUT("SLIMTX8", NULL, 0, | ||
617 | ARIZONA_SLIMBUS_TX_CHANNEL_ENABLE, | ||
618 | ARIZONA_SLIMTX8_ENA_SHIFT, 0), | ||
619 | |||
552 | SND_SOC_DAPM_AIF_OUT("AIF3TX1", NULL, 0, | 620 | SND_SOC_DAPM_AIF_OUT("AIF3TX1", NULL, 0, |
553 | ARIZONA_AIF3_TX_ENABLES, ARIZONA_AIF3TX1_ENA_SHIFT, 0), | 621 | ARIZONA_AIF3_TX_ENABLES, ARIZONA_AIF3TX1_ENA_SHIFT, 0), |
554 | SND_SOC_DAPM_AIF_OUT("AIF3TX2", NULL, 0, | 622 | SND_SOC_DAPM_AIF_OUT("AIF3TX2", NULL, 0, |
@@ -639,6 +707,15 @@ ARIZONA_MIXER_WIDGETS(AIF2TX2, "AIF2TX2"), | |||
639 | ARIZONA_MIXER_WIDGETS(AIF3TX1, "AIF3TX1"), | 707 | ARIZONA_MIXER_WIDGETS(AIF3TX1, "AIF3TX1"), |
640 | ARIZONA_MIXER_WIDGETS(AIF3TX2, "AIF3TX2"), | 708 | ARIZONA_MIXER_WIDGETS(AIF3TX2, "AIF3TX2"), |
641 | 709 | ||
710 | ARIZONA_MIXER_WIDGETS(SLIMTX1, "SLIMTX1"), | ||
711 | ARIZONA_MIXER_WIDGETS(SLIMTX2, "SLIMTX2"), | ||
712 | ARIZONA_MIXER_WIDGETS(SLIMTX3, "SLIMTX3"), | ||
713 | ARIZONA_MIXER_WIDGETS(SLIMTX4, "SLIMTX4"), | ||
714 | ARIZONA_MIXER_WIDGETS(SLIMTX5, "SLIMTX5"), | ||
715 | ARIZONA_MIXER_WIDGETS(SLIMTX6, "SLIMTX6"), | ||
716 | ARIZONA_MIXER_WIDGETS(SLIMTX7, "SLIMTX7"), | ||
717 | ARIZONA_MIXER_WIDGETS(SLIMTX8, "SLIMTX8"), | ||
718 | |||
642 | ARIZONA_MUX_WIDGETS(ASRC1L, "ASRC1L"), | 719 | ARIZONA_MUX_WIDGETS(ASRC1L, "ASRC1L"), |
643 | ARIZONA_MUX_WIDGETS(ASRC1R, "ASRC1R"), | 720 | ARIZONA_MUX_WIDGETS(ASRC1R, "ASRC1R"), |
644 | ARIZONA_MUX_WIDGETS(ASRC2L, "ASRC2L"), | 721 | ARIZONA_MUX_WIDGETS(ASRC2L, "ASRC2L"), |
@@ -689,6 +766,14 @@ SND_SOC_DAPM_OUTPUT("MICSUPP"), | |||
689 | { name, "AIF2RX2", "AIF2RX2" }, \ | 766 | { name, "AIF2RX2", "AIF2RX2" }, \ |
690 | { name, "AIF3RX1", "AIF3RX1" }, \ | 767 | { name, "AIF3RX1", "AIF3RX1" }, \ |
691 | { name, "AIF3RX2", "AIF3RX2" }, \ | 768 | { name, "AIF3RX2", "AIF3RX2" }, \ |
769 | { name, "SLIMRX1", "SLIMRX1" }, \ | ||
770 | { name, "SLIMRX2", "SLIMRX2" }, \ | ||
771 | { name, "SLIMRX3", "SLIMRX3" }, \ | ||
772 | { name, "SLIMRX4", "SLIMRX4" }, \ | ||
773 | { name, "SLIMRX5", "SLIMRX5" }, \ | ||
774 | { name, "SLIMRX6", "SLIMRX6" }, \ | ||
775 | { name, "SLIMRX7", "SLIMRX7" }, \ | ||
776 | { name, "SLIMRX8", "SLIMRX8" }, \ | ||
692 | { name, "EQ1", "EQ1" }, \ | 777 | { name, "EQ1", "EQ1" }, \ |
693 | { name, "EQ2", "EQ2" }, \ | 778 | { name, "EQ2", "EQ2" }, \ |
694 | { name, "EQ3", "EQ3" }, \ | 779 | { name, "EQ3", "EQ3" }, \ |
@@ -776,13 +861,41 @@ static const struct snd_soc_dapm_route wm5110_dapm_routes[] = { | |||
776 | { "AIF3RX1", NULL, "AIF3 Playback" }, | 861 | { "AIF3RX1", NULL, "AIF3 Playback" }, |
777 | { "AIF3RX2", NULL, "AIF3 Playback" }, | 862 | { "AIF3RX2", NULL, "AIF3 Playback" }, |
778 | 863 | ||
864 | { "Slim1 Capture", NULL, "SLIMTX1" }, | ||
865 | { "Slim1 Capture", NULL, "SLIMTX2" }, | ||
866 | { "Slim1 Capture", NULL, "SLIMTX3" }, | ||
867 | { "Slim1 Capture", NULL, "SLIMTX4" }, | ||
868 | |||
869 | { "SLIMRX1", NULL, "Slim1 Playback" }, | ||
870 | { "SLIMRX2", NULL, "Slim1 Playback" }, | ||
871 | { "SLIMRX3", NULL, "Slim1 Playback" }, | ||
872 | { "SLIMRX4", NULL, "Slim1 Playback" }, | ||
873 | |||
874 | { "Slim2 Capture", NULL, "SLIMTX5" }, | ||
875 | { "Slim2 Capture", NULL, "SLIMTX6" }, | ||
876 | |||
877 | { "SLIMRX5", NULL, "Slim2 Playback" }, | ||
878 | { "SLIMRX6", NULL, "Slim2 Playback" }, | ||
879 | |||
880 | { "Slim3 Capture", NULL, "SLIMTX7" }, | ||
881 | { "Slim3 Capture", NULL, "SLIMTX8" }, | ||
882 | |||
883 | { "SLIMRX7", NULL, "Slim3 Playback" }, | ||
884 | { "SLIMRX8", NULL, "Slim3 Playback" }, | ||
885 | |||
779 | { "AIF1 Playback", NULL, "SYSCLK" }, | 886 | { "AIF1 Playback", NULL, "SYSCLK" }, |
780 | { "AIF2 Playback", NULL, "SYSCLK" }, | 887 | { "AIF2 Playback", NULL, "SYSCLK" }, |
781 | { "AIF3 Playback", NULL, "SYSCLK" }, | 888 | { "AIF3 Playback", NULL, "SYSCLK" }, |
889 | { "Slim1 Playback", NULL, "SYSCLK" }, | ||
890 | { "Slim2 Playback", NULL, "SYSCLK" }, | ||
891 | { "Slim3 Playback", NULL, "SYSCLK" }, | ||
782 | 892 | ||
783 | { "AIF1 Capture", NULL, "SYSCLK" }, | 893 | { "AIF1 Capture", NULL, "SYSCLK" }, |
784 | { "AIF2 Capture", NULL, "SYSCLK" }, | 894 | { "AIF2 Capture", NULL, "SYSCLK" }, |
785 | { "AIF3 Capture", NULL, "SYSCLK" }, | 895 | { "AIF3 Capture", NULL, "SYSCLK" }, |
896 | { "Slim1 Capture", NULL, "SYSCLK" }, | ||
897 | { "Slim2 Capture", NULL, "SYSCLK" }, | ||
898 | { "Slim3 Capture", NULL, "SYSCLK" }, | ||
786 | 899 | ||
787 | { "IN1L PGA", NULL, "IN1L" }, | 900 | { "IN1L PGA", NULL, "IN1L" }, |
788 | { "IN1R PGA", NULL, "IN1R" }, | 901 | { "IN1R PGA", NULL, "IN1R" }, |
@@ -828,6 +941,15 @@ static const struct snd_soc_dapm_route wm5110_dapm_routes[] = { | |||
828 | ARIZONA_MIXER_ROUTES("AIF3TX1", "AIF3TX1"), | 941 | ARIZONA_MIXER_ROUTES("AIF3TX1", "AIF3TX1"), |
829 | ARIZONA_MIXER_ROUTES("AIF3TX2", "AIF3TX2"), | 942 | ARIZONA_MIXER_ROUTES("AIF3TX2", "AIF3TX2"), |
830 | 943 | ||
944 | ARIZONA_MIXER_ROUTES("SLIMTX1", "SLIMTX1"), | ||
945 | ARIZONA_MIXER_ROUTES("SLIMTX2", "SLIMTX2"), | ||
946 | ARIZONA_MIXER_ROUTES("SLIMTX3", "SLIMTX3"), | ||
947 | ARIZONA_MIXER_ROUTES("SLIMTX4", "SLIMTX4"), | ||
948 | ARIZONA_MIXER_ROUTES("SLIMTX5", "SLIMTX5"), | ||
949 | ARIZONA_MIXER_ROUTES("SLIMTX6", "SLIMTX6"), | ||
950 | ARIZONA_MIXER_ROUTES("SLIMTX7", "SLIMTX7"), | ||
951 | ARIZONA_MIXER_ROUTES("SLIMTX8", "SLIMTX8"), | ||
952 | |||
831 | ARIZONA_MIXER_ROUTES("EQ1", "EQ1"), | 953 | ARIZONA_MIXER_ROUTES("EQ1", "EQ1"), |
832 | ARIZONA_MIXER_ROUTES("EQ2", "EQ2"), | 954 | ARIZONA_MIXER_ROUTES("EQ2", "EQ2"), |
833 | ARIZONA_MIXER_ROUTES("EQ3", "EQ3"), | 955 | ARIZONA_MIXER_ROUTES("EQ3", "EQ3"), |
@@ -962,6 +1084,63 @@ static struct snd_soc_dai_driver wm5110_dai[] = { | |||
962 | .ops = &arizona_dai_ops, | 1084 | .ops = &arizona_dai_ops, |
963 | .symmetric_rates = 1, | 1085 | .symmetric_rates = 1, |
964 | }, | 1086 | }, |
1087 | { | ||
1088 | .name = "wm5110-slim1", | ||
1089 | .id = 4, | ||
1090 | .playback = { | ||
1091 | .stream_name = "Slim1 Playback", | ||
1092 | .channels_min = 1, | ||
1093 | .channels_max = 4, | ||
1094 | .rates = WM5110_RATES, | ||
1095 | .formats = WM5110_FORMATS, | ||
1096 | }, | ||
1097 | .capture = { | ||
1098 | .stream_name = "Slim1 Capture", | ||
1099 | .channels_min = 1, | ||
1100 | .channels_max = 4, | ||
1101 | .rates = WM5110_RATES, | ||
1102 | .formats = WM5110_FORMATS, | ||
1103 | }, | ||
1104 | .ops = &arizona_simple_dai_ops, | ||
1105 | }, | ||
1106 | { | ||
1107 | .name = "wm5110-slim2", | ||
1108 | .id = 5, | ||
1109 | .playback = { | ||
1110 | .stream_name = "Slim2 Playback", | ||
1111 | .channels_min = 1, | ||
1112 | .channels_max = 2, | ||
1113 | .rates = WM5110_RATES, | ||
1114 | .formats = WM5110_FORMATS, | ||
1115 | }, | ||
1116 | .capture = { | ||
1117 | .stream_name = "Slim2 Capture", | ||
1118 | .channels_min = 1, | ||
1119 | .channels_max = 2, | ||
1120 | .rates = WM5110_RATES, | ||
1121 | .formats = WM5110_FORMATS, | ||
1122 | }, | ||
1123 | .ops = &arizona_simple_dai_ops, | ||
1124 | }, | ||
1125 | { | ||
1126 | .name = "wm5110-slim3", | ||
1127 | .id = 6, | ||
1128 | .playback = { | ||
1129 | .stream_name = "Slim3 Playback", | ||
1130 | .channels_min = 1, | ||
1131 | .channels_max = 2, | ||
1132 | .rates = WM5110_RATES, | ||
1133 | .formats = WM5110_FORMATS, | ||
1134 | }, | ||
1135 | .capture = { | ||
1136 | .stream_name = "Slim3 Capture", | ||
1137 | .channels_min = 1, | ||
1138 | .channels_max = 2, | ||
1139 | .rates = WM5110_RATES, | ||
1140 | .formats = WM5110_FORMATS, | ||
1141 | }, | ||
1142 | .ops = &arizona_simple_dai_ops, | ||
1143 | }, | ||
965 | }; | 1144 | }; |
966 | 1145 | ||
967 | static int wm5110_codec_probe(struct snd_soc_codec *codec) | 1146 | static int wm5110_codec_probe(struct snd_soc_codec *codec) |