Debian Codegraph @

Documentation/devicetree/bindings/sound/wlf,wm8960.yaml

raw
1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/sound/wlf,wm8960.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Wolfson WM8960 audio codec
8
9 maintainers:
10 - [email protected]
11
12 description: |
13 Wolfson WM8960 audio codec
14
15 Pins on the device (for linking into audio routes):
16
17 Outputs:
18 * HP_L : Left Headphone/Line Output
19 * HP_R : Right Headphone/Line Output
20 * SPK_LP : Left Speaker Output (Positive)
21 * SPK_LN : Left Speaker Output (Negative)
22 * SPK_RP : Right Speaker Output (Positive)
23 * SPK_RN : Right Speaker Output (Negative)
24 * OUT3 : Mono, Left, Right or buffered midrail output for capless mode
25
26 Inputs:
27 * LINPUT1 : Left single-ended or negative differential microphone input
28 * RINPUT1 : Right single-ended or negative differential microphone input
29 * LINPUT2 : Left line input or positive differential microphone input
30 * RINPUT2 : Right line input or positive differential microphone input
31 * LINPUT3 : Left line input, positive differential microphone, or Jack Detect 2
32 * RINPUT3 : Right line input, positive differential microphone, or Jack Detect 3
33
34 properties:
35 compatible:
36 const: wlf,wm8960
37
38 reg:
39 maxItems: 1
40
41 clocks:
42 maxItems: 1
43
44 clock-names:
45 items:
46 - const: mclk
47
48 '#sound-dai-cells':
49 const: 0
50
51 AVDD-supply:
52 description: Analogue supply.
53
54 DBVDD-supply:
55 description: Digital Buffer Supply.
56
57 DCVDD-supply:
58 description: Digital Core Supply.
59
60 SPKVDD1-supply:
61 description: Supply for speaker drivers 1.
62
63 SPKVDD2-supply:
64 description: Supply for speaker drivers 2.
65
66 wlf,capless:
67 type: boolean
68 description:
69 If present, OUT3 pin will be enabled and disabled together with HP_L and
70 HP_R pins in response to jack detect events.
71
72 wlf,gpio-cfg:
73 $ref: /schemas/types.yaml#/definitions/uint32-array
74 maxItems: 2
75 description: |
76 A list of GPIO configuration register values.
77 - gpio-cfg[0]: ALRCGPIO of R9 (Audio interface)
78 - gpio-cfg[1]: {GPIOPOL:GPIOSEL[2:0]} of R48 (Additional Control 4).
79
80 wlf,hp-cfg:
81 $ref: /schemas/types.yaml#/definitions/uint32-array
82 maxItems: 3
83 description: |
84 A list of headphone jack detect configuration register values:
85 - hp-cfg[0]: HPSEL[1:0] of R48 (Additional Control 4).
86 - hp-cfg[1]: {HPSWEN:HPSWPOL} of R24 (Additional Control 2).
87 - hp-cfg[2]: {TOCLKSEL:TOEN} of R23 (Additional Control 1).
88
89 wlf,shared-lrclk:
90 type: boolean
91 description:
92 If present, the LRCM bit of R24 (Additional control 2) gets set,
93 indicating that ADCLRC and DACLRC pins will be disabled only when ADC
94 (Left and Right) and DAC (Left and Right) are disabled.
95 When WM8960 works on synchronize mode and DACLRC pin is used to supply
96 frame clock, it will no frame clock for captrue unless enable DAC to
97 enable DACLRC pin. If shared-lrclk is present, no need to enable DAC for
98 captrue.
99
100 port:
101 $ref: audio-graph-port.yaml#
102 unevaluatedProperties: false
103
104 required:
105 - compatible
106 - reg
107
108 allOf:
109 - $ref: dai-common.yaml#
110
111 unevaluatedProperties: false
112
113 examples:
114 - |
115 i2c {
116 #address-cells = <1>;
117 #size-cells = <0>;
118
119 audio-codec@1a {
120 compatible = "wlf,wm8960";
121 reg = <0x1a>;
122 clocks = <&clks 0>;
123 clock-names = "mclk";
124 #sound-dai-cells = <0>;
125 wlf,hp-cfg = <3 2 3>;
126 wlf,gpio-cfg = <1 3>;
127 wlf,shared-lrclk;
128 DCVDD-supply = <&reg_audio>;
129 DBVDD-supply = <&reg_audio>;
130 AVDD-supply = <&reg_audio>;
131 SPKVDD1-supply = <&reg_audio>;
132 SPKVDD2-supply = <&reg_audio>;
133 };
134 };