Cirrus Logic Madera class audio CODECs Multi-Functional Device

Schema identifier ($id): "http://devicetree.org/schemas/mfd/cirrus,madera.yaml#"

Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"

Maintainers (maintainers): "patches@opensource.cirrus.com"

These devices are audio SoCs with extensive digital capabilities and a range of analogue I/O.

See also the child driver bindings in:

  bindings/pinctrl/cirrus,madera.yaml
  bindings/regulator/wlf,arizona.yaml
  bindings/sound/cirrus,madera.yaml

All of these rules must match (allOf) #

Rule 1 #

Shared schema rule ($ref): /schemas/pinctrl/cirrus,madera.yaml#

Rule 2 #

Shared schema rule ($ref): /schemas/regulator/wlf,arizona.yaml#

Rule 3 #

Shared schema rule ($ref): /schemas/sound/cirrus,madera.yaml#

Rule 4 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "cirrus,cs47l85", "wlf,wm1840"

When the condition matches (then) #

Properties and child nodes (properties)

SPKVDDL-supply — required here

Left speaker driver power supply.

SPKVDDR-supply — required here

Right speaker driver power supply.

Required in this object (required): "SPKVDDL-supply", "SPKVDDR-supply"

When the condition does not match (else) #

Required in this object (required): "DCVDD-supply"

Rule 5 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "cirrus,cs47l15", "cirrus,cs47l35"

When the condition matches (then) #

Properties and child nodes (properties)

SPKVDD-supply — required here

Mono speaker driver power supply.

Required in this object (required): "SPKVDD-supply"

Rule 6 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "cirrus,cs47l35", "cirrus,cs47l85", "cirrus,cs47l90", "cirrus,cs47l91", "wlf,wm1840"

When the condition matches (then) #

Properties and child nodes (properties)

DBVDD2-supply — required here

Databus power supply.

Required in this object (required): "DBVDD2-supply"

Rule 7 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "cirrus,cs47l85", "cirrus,cs47l90", "cirrus,cs47l91", "wlf,wm1840"

When the condition matches (then) #

Properties and child nodes (properties)

DBVDD3-supply — not listed as required here

Databus power supply.

DBVDD4-supply — not listed as required here

Databus power supply.

Rule 8 #

Condition (if) #

Properties and child nodes (properties)

compatible — not listed as required here

Rule for matching array elements (contains)

Allowed values (enum): "cirrus,cs47l15"

When the condition matches (then) #

Required in this object (required): "MICVDD-supply"

When the condition does not match (else) #

Properties and child nodes (properties)

CPVDD2-supply — required here

Secondary charge pump power supply.

Required in this object (required): "CPVDD2-supply"

Properties and child nodes (properties) #

compatible — required here #

Allowed values (enum): "cirrus,cs47l15", "cirrus,cs47l35", "cirrus,cs47l85", "cirrus,cs47l90", "cirrus,cs47l91", "cirrus,cs42l92", "cirrus,cs47l92", "cirrus,cs47l93", "cirrus,wm1840"

reg — not listed as required here #

Maximum number of items (maxItems): 1

gpio-controller — required here #

true — No constraints added by this property rule.

#gpio-cells — required here #

The first cell is the pin number. The second cell is reserved for future use and must be zero

Exact value (const): 2

interrupt-controller — required here #

true — No constraints added by this property rule.

#interrupt-cells — required here #

The first cell is the IRQ number. The second cell is the flags, encoded as the trigger masks from bindings/interrupt-controller/interrupts.txt

Exact value (const): 2

interrupts — required here #

Maximum number of items (maxItems): 1

reset-gpios — not listed as required here #

One entry specifying the GPIO controlling /RESET. As defined in bindings/gpio.txt. Although optional, it is strongly recommended to use a hardware reset.

Maximum number of items (maxItems): 1

clocks — not listed as required here #

Should reference the clocks supplied on MCLK1, MCLK2 and MCLK3.

Minimum number of items (minItems): 1

Maximum number of items (maxItems): 3

clock-names — not listed as required here #

May contain up to three strings:
  "mclk1" For the clock supplied on MCLK1, recommended to be a
          high quality audio reference clock.
  "mclk2" For the clock supplied on MCLK2, required to be an
          always on 32k clock.
  "mclk3" For the clock supplied on MCLK3.

Exactly one of these rules must match (oneOf) #

Rule 1

Array item rules (items)

Item 1

Exact value (const): "mclk1"

Rule 2

Array item rules (items)

Item 1

Exact value (const): "mclk2"

Rule 3

Array item rules (items)

Item 1

Exact value (const): "mclk3"

Rule 4

Array item rules (items)

Item 1

Exact value (const): "mclk1"

Item 2

Exact value (const): "mclk2"

Rule 5

Array item rules (items)

Item 1

Exact value (const): "mclk1"

Item 2

Exact value (const): "mclk3"

Rule 6

Array item rules (items)

Item 1

Exact value (const): "mclk2"

Item 2

Exact value (const): "mclk3"

Rule 7

Array item rules (items)

Item 1

Exact value (const): "mclk1"

Item 2

Exact value (const): "mclk2"

Item 3

Exact value (const): "mclk3"

AVDD-supply — required here #

Analogue power supply.

DBVDD1-supply — required here #

Databus power supply.

CPVDD1-supply — required here #

Charge pump power supply.

DCVDD-supply — not listed as required here #

Digital power supply, optional on CS47L85, WM1840 where it can be supplied internally.

MICVDD-supply — not listed as required here #

Microphone power supply, normally supplied internally except on cs47l24, wm1831 where it is mandatory.

Required in this object (required): "compatible", "gpio-controller", "#gpio-cells", "interrupt-controller", "#interrupt-cells", "interrupts", "AVDD-supply", "DBVDD1-supply", "CPVDD1-supply"

Properties not evaluated by applicable rules (unevaluatedProperties) #

false

Not allowed by this rule.

Examples (examples) #

#include <dt-bindings/sound/madera.h>
i2c@e0004000 {
    #address-cells = <1>;
    #size-cells = <0>;
    reg = <0xe0004000 0x1000>;

    cs47l85: codec@1a {
        compatible = "cirrus,cs47l85";
        reg = <0x1a>;

        reset-gpios = <&gpio 0>;
        wlf,ldoena = <&gpio 1>;

        interrupt-controller;
        #interrupt-cells = <2>;
        interrupts = <4 1 0>;

        gpio-controller;
        #gpio-cells = <2>;

        AVDD-supply = <&vdd1v8>;
        DBVDD1-supply = <&vdd1v8>;
        DBVDD2-supply = <&vdd1v8>;
        DBVDD3-supply = <&vdd1v8>;
        DBVDD4-supply = <&vdd1v8>;
        CPVDD1-supply = <&vdd1v8>;
        CPVDD2-supply = <&vdd1v2>;
        SPKVDDL-supply = <&vdd5v>;
        SPKVDDR-supply = <&vdd5v>;

        clocks = <&clks 0>, <&clks 1>, <&clks 2>;
        clock-names = "mclk1", "mclk2", "mclk3";

        cirrus,dmic-ref = <0 0 MADERA_DMIC_REF_MICBIAS1>;
        cirrus,inmode = <
            MADERA_INMODE_SE   MADERA_INMODE_SE
            MADERA_INMODE_SE   MADERA_INMODE_SE
            MADERA_INMODE_DIFF MADERA_INMODE_DIFF
        >;
        cirrus,max-channels-clocked = <2 0 0>;

        pinctrl-names = "default";
        pinctrl-0 = <&pinsettings>;

        pinsettings: pin-settings {
            aif1-pins {
                groups = "aif1";
                function = "aif1";
                bias-bus-hold;
            };

            aif2-pins {
                groups = "aif2";
                function = "aif2";
                bias-bus-hold;
            };

            aif3-pins {
                groups = "aif3";
                function = "aif3";
                bias-bus-hold;
            };
        };
    };
};

Source notes #

Annotations retained from the schema source

Line 1: SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause

Edit this page