forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f70575805708cabdedea7498aaa3f710fde4d920
kernel/sound/soc/pxa/em-x270.c
....@@ -1,3 +1,4 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * SoC audio driver for EM-X270, eXeda and CM-X300
34 *
....@@ -11,12 +12,6 @@
1112 *
1213 * Authors: Liam Girdwood <lrg@slimlogic.co.uk>
1314 * Richard Purdie <richard@openedhand.com>
14
- *
15
- * This program is free software; you can redistribute it and/or modify it
16
- * under the terms of the GNU General Public License as published by the
17
- * Free Software Foundation; either version 2 of the License, or (at your
18
- * option) any later version.
19
- *
2015 */
2116
2217 #include <linux/module.h>
....@@ -30,22 +25,26 @@
3025 #include <asm/mach-types.h>
3126 #include <mach/audio.h>
3227
28
+SND_SOC_DAILINK_DEFS(ac97,
29
+ DAILINK_COMP_ARRAY(COMP_CPU("pxa2xx-ac97")),
30
+ DAILINK_COMP_ARRAY(COMP_CODEC("wm9712-codec", "wm9712-hifi")),
31
+ DAILINK_COMP_ARRAY(COMP_PLATFORM("pxa-pcm-audio")));
32
+
33
+SND_SOC_DAILINK_DEFS(ac97_aux,
34
+ DAILINK_COMP_ARRAY(COMP_CPU("pxa2xx-ac97-aux")),
35
+ DAILINK_COMP_ARRAY(COMP_CODEC("wm9712-codec", "wm9712-aux")),
36
+ DAILINK_COMP_ARRAY(COMP_PLATFORM("pxa-pcm-audio")));
37
+
3338 static struct snd_soc_dai_link em_x270_dai[] = {
3439 {
3540 .name = "AC97",
3641 .stream_name = "AC97 HiFi",
37
- .cpu_dai_name = "pxa2xx-ac97",
38
- .codec_dai_name = "wm9712-hifi",
39
- .platform_name = "pxa-pcm-audio",
40
- .codec_name = "wm9712-codec",
42
+ SND_SOC_DAILINK_REG(ac97),
4143 },
4244 {
4345 .name = "AC97 Aux",
4446 .stream_name = "AC97 Aux",
45
- .cpu_dai_name = "pxa2xx-ac97-aux",
46
- .codec_dai_name = "wm9712-aux",
47
- .platform_name = "pxa-pcm-audio",
48
- .codec_name = "wm9712-codec",
47
+ SND_SOC_DAILINK_REG(ac97_aux),
4948 },
5049 };
5150