Merge remote-tracking branches 'asoc/topic/ac97', 'asoc/topic/arizona', 'asoc/topic...
[deliverable/linux.git] / Documentation / devicetree / bindings / sound / simple-scu-card.txt
CommitLineData
64df0e68 1ASoC simple SCU Sound Card
415f1cb2 2
64df0e68 3Simple-Card specifies audio DAI connections of SoC <-> codec.
415f1cb2
KM
4
5Required properties:
6
64df0e68
KM
7- compatible : "simple-scu-audio-card"
8 "renesas,rsrc-card"
a3235938 9
415f1cb2
KM
10Optional properties:
11
64df0e68 12- simple-audio-card,name : User specified audio sound card name, one string
415f1cb2 13 property.
64df0e68
KM
14- simple-audio-card,cpu : CPU sub-node
15- simple-audio-card,codec : CODEC sub-node
415f1cb2
KM
16
17Optional subnode properties:
18
64df0e68 19- simple-audio-card,format : CPU/CODEC common audio format.
415f1cb2
KM
20 "i2s", "right_j", "left_j" , "dsp_a"
21 "dsp_b", "ac97", "pdm", "msb", "lsb"
64df0e68 22- simple-audio-card,frame-master : Indicates dai-link frame master.
415f1cb2 23 phandle to a cpu or codec subnode.
64df0e68 24- simple-audio-card,bitclock-master : Indicates dai-link bit clock master.
415f1cb2 25 phandle to a cpu or codec subnode.
64df0e68 26- simple-audio-card,bitclock-inversion : bool property. Add this if the
415f1cb2 27 dai-link uses bit clock inversion.
64df0e68 28- simple-audio-card,frame-inversion : bool property. Add this if the
415f1cb2 29 dai-link uses frame clock inversion.
64df0e68
KM
30- simple-audio-card,convert-rate : platform specified sampling rate convert
31- simple-audio-card,convert-channels : platform specified converted channel size (2 - 8 ch)
32- simple-audio-card,prefix : see audio-routing
33- simple-audio-card,routing : A list of the connections between audio components.
b7419dd7
KM
34 Each entry is a pair of strings, the first being the connection's sink,
35 the second being the connection's source. Valid names for sources.
36 use audio-prefix if some components is using same sink/sources naming.
37 it can be used if compatible was "renesas,rsrc-card";
415f1cb2
KM
38
39Required CPU/CODEC subnodes properties:
40
41- sound-dai : phandle and port of CPU/CODEC
42
43Optional CPU/CODEC subnodes properties:
44
45- clocks / system-clock-frequency : specify subnode's clock if needed.
46 it can be specified via "clocks" if system has
47 clock node (= common clock), or "system-clock-frequency"
48 (if system doens't support common clock)
49 If a clock is specified, it is
50 enabled with clk_prepare_enable()
51 in dai startup() and disabled with
52 clk_disable_unprepare() in dai
53 shutdown().
54
e5a01eb5 55Example 1. Sampling Rate Covert
415f1cb2
KM
56
57sound {
64df0e68 58 compatible = "simple-scu-audio-card";
415f1cb2 59
64df0e68
KM
60 simple-audio-card,name = "rsnd-ak4643";
61 simple-audio-card,format = "left_j";
62 simple-audio-card,format = "left_j";
63 simple-audio-card,bitclock-master = <&sndcodec>;
64 simple-audio-card,frame-master = <&sndcodec>;
415f1cb2 65
64df0e68
KM
66 simple-audio-card,convert-rate = <48000>; /* see audio_clk_a */
67
68 simple-audio-card,prefix = "ak4642";
69 simple-audio-card,routing = "ak4642 Playback", "DAI0 Playback",
70 "DAI0 Capture", "ak4642 Capture";
71
72 sndcpu: simple-audio-card,cpu {
415f1cb2
KM
73 sound-dai = <&rcar_sound>;
74 };
75
64df0e68 76 sndcodec: simple-audio-card,codec {
415f1cb2
KM
77 sound-dai = <&ak4643>;
78 system-clock-frequency = <11289600>;
79 };
80};
e5a01eb5
KM
81
82Example 2. 2 CPU 1 Codec
83
84sound {
85 compatible = "renesas,rsrc-card";
86
87 card-name = "rsnd-ak4643";
88 format = "left_j";
89 bitclock-master = <&dpcmcpu>;
90 frame-master = <&dpcmcpu>;
91
92 convert-rate = <48000>; /* see audio_clk_a */
93
94 audio-prefix = "ak4642";
95 audio-routing = "ak4642 Playback", "DAI0 Playback",
96 "ak4642 Playback", "DAI1 Playback";
97
98 dpcmcpu: cpu@0 {
99 sound-dai = <&rcar_sound 0>;
100 };
101
102 cpu@1 {
103 sound-dai = <&rcar_sound 1>;
104 };
105
106 codec {
107 sound-dai = <&ak4643>;
108 clocks = <&audio_clock>;
109 };
110};
This page took 0.076399 seconds and 5 git commands to generate.