Mention branches and keyring.
[releases.git] / bindings / pinctrl / cypress,cy8c95x0.yaml
1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2 %YAML 1.2
3 ---
4 $id: http://devicetree.org/schemas/pinctrl/cypress,cy8c95x0.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
6
7 title: Cypress CY8C95X0 I2C GPIO expander
8
9 maintainers:
10   - Patrick Rudolph <patrick.rudolph@9elements.com>
11
12 description: |
13   This supports the 20/40/60 pin Cypress CYC95x0 GPIO I2C expanders.
14   Pin function configuration is performed on a per-pin basis.
15
16 properties:
17   compatible:
18     enum:
19       - cypress,cy8c9520
20       - cypress,cy8c9540
21       - cypress,cy8c9560
22
23   reg:
24     maxItems: 1
25
26   gpio-controller: true
27
28   '#gpio-cells':
29     description:
30       The first cell is the GPIO number and the second cell specifies GPIO
31       flags, as defined in <dt-bindings/gpio/gpio.h>.
32     const: 2
33
34   interrupts:
35     maxItems: 1
36
37   interrupt-controller: true
38
39   '#interrupt-cells':
40     const: 2
41
42   gpio-line-names: true
43
44   gpio-ranges:
45     maxItems: 1
46
47   gpio-reserved-ranges:
48     maxItems: 1
49
50   vdd-supply:
51     description:
52       Optional power supply.
53
54   reset-gpios:
55     description: GPIO connected to the XRES pin
56     maxItems: 1
57
58 patternProperties:
59   '-pins$':
60     type: object
61     description:
62       Pinctrl node's client devices use subnodes for desired pin configuration.
63       Client device subnodes use below standard properties.
64     $ref: pincfg-node.yaml#
65
66     properties:
67       pins:
68         description:
69           List of gpio pins affected by the properties specified in this
70           subnode.
71         items:
72           pattern: '^gp([0-7][0-7])$'
73         minItems: 1
74         maxItems: 60
75
76       function:
77         description:
78           Specify the alternative function to be configured for the specified
79           pins.
80         enum: [ gpio, pwm ]
81
82       bias-pull-down: true
83
84       bias-pull-up: true
85
86       bias-disable: true
87
88       output-high: true
89
90       output-low: true
91
92       drive-push-pull: true
93
94       drive-open-drain: true
95
96       drive-open-source: true
97
98     required:
99       - pins
100       - function
101
102     additionalProperties: false
103
104 required:
105   - compatible
106   - reg
107   - interrupts
108   - interrupt-controller
109   - '#interrupt-cells'
110   - gpio-controller
111   - '#gpio-cells'
112
113 additionalProperties: false
114
115 allOf:
116   - $ref: pinctrl.yaml#
117
118 examples:
119   - |
120     #include <dt-bindings/interrupt-controller/arm-gic.h>
121     #include <dt-bindings/interrupt-controller/irq.h>
122
123     i2c {
124       #address-cells = <1>;
125       #size-cells = <0>;
126
127       pinctrl@20 {
128         compatible = "cypress,cy8c9520";
129         reg = <0x20>;
130         gpio-controller;
131         #gpio-cells = <2>;
132         #interrupt-cells = <2>;
133         interrupts = <GIC_SPI 94 IRQ_TYPE_LEVEL_HIGH>;
134         interrupt-controller;
135         vdd-supply = <&p3v3>;
136         gpio-reserved-ranges = <5 1>;
137       };
138     };