File tree Expand file tree Collapse file tree 2 files changed +27
-0
lines changed
Documentation/devicetree/bindings/sound Expand file tree Collapse file tree 2 files changed +27
-0
lines changed Original file line number Diff line number Diff line change
1
+ Device-Tree bindings for dummy HDMI codec
2
+
3
+ Required properties:
4
+ - compatible: should be "linux,hdmi-audio".
5
+
6
+ CODEC output pins:
7
+ * TX
8
+
9
+ CODEC input pins:
10
+ * RX
11
+
12
+ Example node:
13
+
14
+ hdmi_audio: hdmi_audio@0 {
15
+ compatible = "linux,hdmi-audio";
16
+ status = "okay";
17
+ };
Original file line number Diff line number Diff line change 20
20
*/
21
21
#include <linux/module.h>
22
22
#include <sound/soc.h>
23
+ #include <linux/of_device.h>
23
24
24
25
#define DRV_NAME "hdmi-audio-codec"
25
26
@@ -60,6 +61,14 @@ static struct snd_soc_dai_driver hdmi_codec_dai = {
60
61
61
62
};
62
63
64
+ #ifdef CONFIG_OF
65
+ static const struct of_device_id hdmi_audio_codec_ids [] = {
66
+ { .compatible = "linux,hdmi-audio" , },
67
+ { }
68
+ };
69
+ MODULE_DEVICE_TABLE (of , hdmi_audio_codec_ids );
70
+ #endif
71
+
63
72
static struct snd_soc_codec_driver hdmi_codec = {
64
73
.dapm_widgets = hdmi_widgets ,
65
74
.num_dapm_widgets = ARRAY_SIZE (hdmi_widgets ),
@@ -83,6 +92,7 @@ static struct platform_driver hdmi_codec_driver = {
83
92
.driver = {
84
93
.name = DRV_NAME ,
85
94
.owner = THIS_MODULE ,
95
+ .of_match_table = of_match_ptr (hdmi_audio_codec_ids ),
86
96
},
87
97
88
98
.probe = hdmi_codec_probe ,
You can’t perform that action at this time.
0 commit comments