1# SPDX-License-Identifier: GPL-2.0-only
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/sound/sgtl5000.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: Freescale SGTL5000 Stereo Codec
8
9maintainers:
10  - Fabio Estevam <festevam@gmail.com>
11
12properties:
13  compatible:
14    const: fsl,sgtl5000
15
16  reg:
17    maxItems: 1
18
19  "#sound-dai-cells":
20    const: 0
21
22  clocks:
23    items:
24      - description: the clock provider of SYS_MCLK
25
26  VDDA-supply:
27    description: the regulator provider of VDDA
28
29  VDDIO-supply:
30    description: the regulator provider of VDDIO
31
32  VDDD-supply:
33    description: the regulator provider of VDDD
34
35  micbias-resistor-k-ohms:
36    description: The bias resistor to be used in kOhms. The resistor can take
37      values of 2k, 4k or 8k. If set to 0 it will be off. If this node is not
38      mentioned or if the value is unknown, then micbias resistor is set to
39      4k.
40    $ref: "/schemas/types.yaml#/definitions/uint32"
41    enum: [ 0, 2, 4, 8 ]
42
43  micbias-voltage-m-volts:
44    description: The bias voltage to be used in mVolts. The voltage can take
45      values from 1.25V to 3V by 250mV steps. If this node is not mentioned
46      or the value is unknown, then the value is set to 1.25V.
47    $ref: "/schemas/types.yaml#/definitions/uint32"
48    enum: [ 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000 ]
49
50  lrclk-strength:
51    description: |
52      The LRCLK pad strength. Possible values are: 0, 1, 2 and 3 as per the
53      table below:
54
55        VDDIO		1.8V		2.5V		3.3V
56        0 =		Disable
57        1 =		1.66 mA		2.87 mA		4.02  mA
58        2 =		3.33 mA		5.74 mA		8.03  mA
59        3 =		4.99 mA		8.61 mA		12.05 mA
60    $ref: "/schemas/types.yaml#/definitions/uint32"
61    enum: [ 0, 1, 2, 3 ]
62
63  sclk-strength:
64    description: |
65      The SCLK pad strength. Possible values are: 0, 1, 2 and 3 as per the
66      table below:
67
68        VDDIO		1.8V		2.5V		3.3V
69        0 =		Disable
70        1 =		1.66 mA		2.87 mA		4.02  mA
71        2 =		3.33 mA		5.74 mA		8.03  mA
72        3 =		4.99 mA		8.61 mA		12.05 mA
73    $ref: "/schemas/types.yaml#/definitions/uint32"
74    enum: [ 0, 1, 2, 3 ]
75
76required:
77  - compatible
78  - reg
79  - "#sound-dai-cells"
80  - clocks
81  - VDDA-supply
82  - VDDIO-supply
83
84additionalProperties: false
85
86examples:
87  - |
88    i2c {
89        #address-cells = <1>;
90        #size-cells = <0>;
91
92        codec@a {
93            compatible = "fsl,sgtl5000";
94            reg = <0x0a>;
95            #sound-dai-cells = <0>;
96            clocks = <&clks 150>;
97            micbias-resistor-k-ohms = <2>;
98            micbias-voltage-m-volts = <2250>;
99            VDDA-supply = <&reg_3p3v>;
100            VDDIO-supply = <&reg_3p3v>;
101        };
102    };
103...
104