18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
28c2ecf20Sopenharmony_ci%YAML 1.2
38c2ecf20Sopenharmony_ci---
48c2ecf20Sopenharmony_ci$id: http://devicetree.org/schemas/pinctrl/cirrus,madera.yaml#
58c2ecf20Sopenharmony_ci$schema: http://devicetree.org/meta-schemas/core.yaml#
68c2ecf20Sopenharmony_ci
78c2ecf20Sopenharmony_cititle: Cirrus Logic Madera class audio CODECs pinctrl driver
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_cimaintainers:
108c2ecf20Sopenharmony_ci  - patches@opensource.cirrus.com
118c2ecf20Sopenharmony_ci
128c2ecf20Sopenharmony_cidescription: |
138c2ecf20Sopenharmony_ci  The Cirrus Logic Madera codecs provide a number of GPIO functions for
148c2ecf20Sopenharmony_ci  interfacing to external hardware and to provide logic outputs to other devices.
158c2ecf20Sopenharmony_ci  Certain groups of GPIO pins also have an alternate function, normally as an
168c2ecf20Sopenharmony_ci  audio interface.
178c2ecf20Sopenharmony_ci
188c2ecf20Sopenharmony_ci  The set of available GPIOs, functions and alternate function groups differs
198c2ecf20Sopenharmony_ci  between CODECs so refer to the datasheet for the CODEC for further information
208c2ecf20Sopenharmony_ci  on what is supported on that device.
218c2ecf20Sopenharmony_ci
228c2ecf20Sopenharmony_ci  The properties for this driver exist within the parent MFD driver node.
238c2ecf20Sopenharmony_ci
248c2ecf20Sopenharmony_ci  See also the core bindings for the parent MFD driver:
258c2ecf20Sopenharmony_ci
268c2ecf20Sopenharmony_ci    Documentation/devicetree/bindings/mfd/cirrus,madera.yaml
278c2ecf20Sopenharmony_ci
288c2ecf20Sopenharmony_ci  And the generic pinmix bindings:
298c2ecf20Sopenharmony_ci
308c2ecf20Sopenharmony_ci    Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
318c2ecf20Sopenharmony_ci
328c2ecf20Sopenharmony_ciproperties:
338c2ecf20Sopenharmony_ci  pinctrl-0:
348c2ecf20Sopenharmony_ci    description:
358c2ecf20Sopenharmony_ci      A phandle to the node containing the subnodes containing default
368c2ecf20Sopenharmony_ci      configurations.
378c2ecf20Sopenharmony_ci
388c2ecf20Sopenharmony_ci  pinctrl-names:
398c2ecf20Sopenharmony_ci    description:
408c2ecf20Sopenharmony_ci      A pinctrl state named "default" must be defined.
418c2ecf20Sopenharmony_ci    const: default
428c2ecf20Sopenharmony_ci
438c2ecf20Sopenharmony_ci  pin-settings:
448c2ecf20Sopenharmony_ci    description:
458c2ecf20Sopenharmony_ci      One subnode is required to contain the default settings. It
468c2ecf20Sopenharmony_ci      contains an arbitrary number of configuration subnodes, one for
478c2ecf20Sopenharmony_ci      each group or pin configuration you want to apply as a default.
488c2ecf20Sopenharmony_ci    type: object
498c2ecf20Sopenharmony_ci    patternProperties:
508c2ecf20Sopenharmony_ci      '-pins$':
518c2ecf20Sopenharmony_ci        type: object
528c2ecf20Sopenharmony_ci        allOf:
538c2ecf20Sopenharmony_ci          - $ref: "pincfg-node.yaml#"
548c2ecf20Sopenharmony_ci          - $ref: "pinmux-node.yaml#"
558c2ecf20Sopenharmony_ci        properties:
568c2ecf20Sopenharmony_ci          groups:
578c2ecf20Sopenharmony_ci            description:
588c2ecf20Sopenharmony_ci              Name of one pin group to configure.
598c2ecf20Sopenharmony_ci            enum: [ aif1, aif2, aif3, aif4, mif1, mif2, mif3, pdmspk1,
608c2ecf20Sopenharmony_ci                    pdmspk2, dmic4, dmic5, dmic6, gpio1, gpio2, gpio3,
618c2ecf20Sopenharmony_ci                    gpio4, gpio5, gpio6, gpio7, gpio7, gpio8, gpio9,
628c2ecf20Sopenharmony_ci                    gpio10, gpio11, gpio12, gpio13, gpio14, gpio15,
638c2ecf20Sopenharmony_ci                    gpio16, gpio17, gpio17, gpio18, gpio19, gpio20,
648c2ecf20Sopenharmony_ci                    gpio21, gpio22, gpio23, gpio24, gpio25, gpio26,
658c2ecf20Sopenharmony_ci                    gpio27, gpio27, gpio28, gpio29, gpio30, gpio31,
668c2ecf20Sopenharmony_ci                    gpio32, gpio33, gpio34, gpio35, gpio36, gpio37,
678c2ecf20Sopenharmony_ci                    gpio37, gpio38, gpio39 ]
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci          function:
708c2ecf20Sopenharmony_ci            description:
718c2ecf20Sopenharmony_ci              Name of function to assign to this group.
728c2ecf20Sopenharmony_ci            enum: [ aif1, aif2, aif3, aif4, mif1, mif2, mif3,
738c2ecf20Sopenharmony_ci                    pdmspk1, pdmspk2, dmic3, dmic4, dmic5,
748c2ecf20Sopenharmony_ci                    dmic6, io, dsp-gpio, irq1, irq2, fll1-clk,
758c2ecf20Sopenharmony_ci                    fll1-lock, fll2-clk, fll2-lock, fll3-clk,
768c2ecf20Sopenharmony_ci                    fll3-lock, fllao-clk, fllao-lock, opclk,
778c2ecf20Sopenharmony_ci                    opclk-async, pwm1, pwm2, spdif, asrc1-in1-lock,
788c2ecf20Sopenharmony_ci                    asrc1-in2-lock, asrc2-in1-lock, asrc2-in2-lock,
798c2ecf20Sopenharmony_ci                    spkl-short-circuit, spkr-short-circuit,
808c2ecf20Sopenharmony_ci                    spk-shutdown, spk-overheat-shutdown,
818c2ecf20Sopenharmony_ci                    spk-overheat-warn, timer1-sts, timer2-sts,
828c2ecf20Sopenharmony_ci                    timer3-sts, timer4-sts, timer5-sts, timer6-sts,
838c2ecf20Sopenharmony_ci                    timer7-sts, timer8-sts, log1-fifo-ne,
848c2ecf20Sopenharmony_ci                    log2-fifo-ne, log3-fifo-ne, log4-fifo-ne,
858c2ecf20Sopenharmony_ci                    log5-fifo-ne, log6-fifo-ne, log7-fifo-ne,
868c2ecf20Sopenharmony_ci                    log8-fifo-ne ]
878c2ecf20Sopenharmony_ci
888c2ecf20Sopenharmony_ci          bias-disable: true
898c2ecf20Sopenharmony_ci
908c2ecf20Sopenharmony_ci          bias-bus-hold: true
918c2ecf20Sopenharmony_ci
928c2ecf20Sopenharmony_ci          bias-pull-up: true
938c2ecf20Sopenharmony_ci
948c2ecf20Sopenharmony_ci          bias-pull-down: true
958c2ecf20Sopenharmony_ci
968c2ecf20Sopenharmony_ci          drive-push-pull: true
978c2ecf20Sopenharmony_ci
988c2ecf20Sopenharmony_ci          drive-open-drain: true
998c2ecf20Sopenharmony_ci
1008c2ecf20Sopenharmony_ci          drive-strength:
1018c2ecf20Sopenharmony_ci            enum: [ 4, 8 ]
1028c2ecf20Sopenharmony_ci
1038c2ecf20Sopenharmony_ci          input-schmitt-enable: true
1048c2ecf20Sopenharmony_ci
1058c2ecf20Sopenharmony_ci          input-schmitt-disable: true
1068c2ecf20Sopenharmony_ci
1078c2ecf20Sopenharmony_ci          input-debounce: true
1088c2ecf20Sopenharmony_ci
1098c2ecf20Sopenharmony_ci          output-low: true
1108c2ecf20Sopenharmony_ci
1118c2ecf20Sopenharmony_ci          output-high: true
1128c2ecf20Sopenharmony_ci
1138c2ecf20Sopenharmony_ci        additionalProperties: false
1148c2ecf20Sopenharmony_ci
1158c2ecf20Sopenharmony_ci        required:
1168c2ecf20Sopenharmony_ci          - groups
1178c2ecf20Sopenharmony_ci
1188c2ecf20Sopenharmony_ci    additionalProperties: false
1198c2ecf20Sopenharmony_ci
1208c2ecf20Sopenharmony_cirequired:
1218c2ecf20Sopenharmony_ci  - pinctrl-0
1228c2ecf20Sopenharmony_ci  - pinctrl-names
1238c2ecf20Sopenharmony_ci
1248c2ecf20Sopenharmony_ciadditionalProperties: true
125