xref: /openbmc/linux/Documentation/devicetree/bindings/sound/cirrus,madera.yaml (revision 6a0e321ea735691e726d84ee29a1a3fd3fc3541a)
18b3f0ed9SCharles Keepax# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
28b3f0ed9SCharles Keepax%YAML 1.2
38b3f0ed9SCharles Keepax---
48b3f0ed9SCharles Keepax$id: http://devicetree.org/schemas/sound/cirrus,madera.yaml#
58b3f0ed9SCharles Keepax$schema: http://devicetree.org/meta-schemas/core.yaml#
68b3f0ed9SCharles Keepax
78b3f0ed9SCharles Keepaxtitle: Cirrus Logic Madera class audio CODECs
88b3f0ed9SCharles Keepax
98b3f0ed9SCharles Keepaxmaintainers:
108b3f0ed9SCharles Keepax  - patches@opensource.cirrus.com
118b3f0ed9SCharles Keepax
128b3f0ed9SCharles Keepaxdescription: |
138b3f0ed9SCharles Keepax  This describes audio configuration bindings for these codecs.
148b3f0ed9SCharles Keepax
158b3f0ed9SCharles Keepax  See also the core bindings for the parent MFD driver:
168b3f0ed9SCharles Keepax
178b3f0ed9SCharles Keepax    Documentation/devicetree/bindings/mfd/cirrus,madera.yaml
188b3f0ed9SCharles Keepax
198b3f0ed9SCharles Keepax  and defines for values used in these bindings:
208b3f0ed9SCharles Keepax
218b3f0ed9SCharles Keepax    include/dt-bindings/sound/madera.h
228b3f0ed9SCharles Keepax
238b3f0ed9SCharles Keepax  The properties are all contained in the parent MFD node.
248b3f0ed9SCharles Keepax
258b3f0ed9SCharles Keepaxproperties:
268b3f0ed9SCharles Keepax  '#sound-dai-cells':
278b3f0ed9SCharles Keepax    description:
288b3f0ed9SCharles Keepax      The first cell indicating the audio interface.
298b3f0ed9SCharles Keepax    const: 1
308b3f0ed9SCharles Keepax
318b3f0ed9SCharles Keepax  cirrus,inmode:
328b3f0ed9SCharles Keepax    description:
338b3f0ed9SCharles Keepax      A list of input mode settings for each input. A maximum
348b3f0ed9SCharles Keepax      of 24 cells, with four cells per input in the order INnAL,
358b3f0ed9SCharles Keepax      INnAR INnBL INnBR.  For non-muxed inputs the first two cells
368b3f0ed9SCharles Keepax      for that input set the mode for the left and right channel
378b3f0ed9SCharles Keepax      and the second two cells must be 0.  For muxed inputs the
388b3f0ed9SCharles Keepax      first two cells for that input set the mode of the left and
398b3f0ed9SCharles Keepax      right A inputs and the second two cells set the mode of the
408b3f0ed9SCharles Keepax      left and right B inputs.  Valid mode values are one of the
418b3f0ed9SCharles Keepax      MADERA_INMODE_xxx. If the array is shorter than the number
428b3f0ed9SCharles Keepax      of inputs the unspecified inputs default to MADERA_INMODE_DIFF.
438b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
448b3f0ed9SCharles Keepax    minItems: 1
458b3f0ed9SCharles Keepax    maxItems: 24
468b3f0ed9SCharles Keepax    items:
478b3f0ed9SCharles Keepax      minimum: 0
488b3f0ed9SCharles Keepax      maximum: 1
498b3f0ed9SCharles Keepax      default: 0
508b3f0ed9SCharles Keepax
518b3f0ed9SCharles Keepax  cirrus,out-mono:
528b3f0ed9SCharles Keepax    description:
538b3f0ed9SCharles Keepax      Mono bit for each output, maximum of six cells if the array
548b3f0ed9SCharles Keepax      is shorter outputs will be set to stereo.
558b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
568b3f0ed9SCharles Keepax    minItems: 1
578b3f0ed9SCharles Keepax    maxItems: 6
588b3f0ed9SCharles Keepax    items:
598b3f0ed9SCharles Keepax      minimum: 0
608b3f0ed9SCharles Keepax      maximum: 1
618b3f0ed9SCharles Keepax      default: 0
628b3f0ed9SCharles Keepax
638b3f0ed9SCharles Keepax  cirrus,dmic-ref:
648b3f0ed9SCharles Keepax    description: |
658b3f0ed9SCharles Keepax      Indicates how the MICBIAS pins have been externally connected
668b3f0ed9SCharles Keepax      to DMICs on each input, one cell per input.
678b3f0ed9SCharles Keepax
688b3f0ed9SCharles Keepax        <IN1 IN2 IN3 ...>
698b3f0ed9SCharles Keepax
708b3f0ed9SCharles Keepax      A value of 0 indicates MICVDD and is the default,
718b3f0ed9SCharles Keepax      other values depend on the codec: For CS47L35 one of the
728b3f0ed9SCharles Keepax      CS47L35_DMIC_REF_xxx values For all other codecs one of
738b3f0ed9SCharles Keepax      the MADERA_DMIC_REF_xxx values Also see the datasheet for a
748b3f0ed9SCharles Keepax      description of the INn_DMIC_SUP field.
758b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
768b3f0ed9SCharles Keepax    minItems: 1
778b3f0ed9SCharles Keepax    maxItems: 6
788b3f0ed9SCharles Keepax    items:
798b3f0ed9SCharles Keepax      minimum: 0
808b3f0ed9SCharles Keepax      maximum: 3
818b3f0ed9SCharles Keepax      default: 0
828b3f0ed9SCharles Keepax
838b3f0ed9SCharles Keepax  cirrus,max-channels-clocked:
848b3f0ed9SCharles Keepax    description:
858b3f0ed9SCharles Keepax      Maximum number of channels that I2S clocks will be generated
868b3f0ed9SCharles Keepax      for. Useful when clock master for systems where the I2S bus
878b3f0ed9SCharles Keepax      has multiple data lines.  One cell for each AIF, use a value
888b3f0ed9SCharles Keepax      of zero for AIFs that should be handled normally.
898b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
908b3f0ed9SCharles Keepax    minItems: 1
918b3f0ed9SCharles Keepax    maxItems: 4
928b3f0ed9SCharles Keepax    items:
938b3f0ed9SCharles Keepax      default: 0
948b3f0ed9SCharles Keepax
958b3f0ed9SCharles Keepax  cirrus,pdm-fmt:
968b3f0ed9SCharles Keepax    description:
978b3f0ed9SCharles Keepax      PDM speaker data format, must contain 2 cells (OUT5 and
988b3f0ed9SCharles Keepax      OUT6). See the PDM_SPKn_FMT field in the datasheet for a
998b3f0ed9SCharles Keepax      description of this value. The second cell is ignored for
1008b3f0ed9SCharles Keepax      codecs that do not have OUT6.
1018b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
1028b3f0ed9SCharles Keepax    minItems: 2
1038b3f0ed9SCharles Keepax    maxItems: 2
1048b3f0ed9SCharles Keepax
1058b3f0ed9SCharles Keepax  cirrus,pdm-mute:
1068b3f0ed9SCharles Keepax    description: |
1078b3f0ed9SCharles Keepax      PDM mute format, must contain 2 cells (OUT5 and OUT6). See the
1088b3f0ed9SCharles Keepax      PDM_SPKn_CTRL_1 register in the datasheet for a description
1098b3f0ed9SCharles Keepax      of this value.  The second cell is ignored for codecs that
1108b3f0ed9SCharles Keepax      do not have OUT6.
1118b3f0ed9SCharles Keepax    $ref: /schemas/types.yaml#/definitions/uint32-array
1128b3f0ed9SCharles Keepax    minItems: 2
1138b3f0ed9SCharles Keepax    maxItems: 2
114*6a0e321eSRob Herring
115*6a0e321eSRob HerringadditionalProperties: true
116