xref: /freebsd/sys/contrib/device-tree/Bindings/gpio/exar,xra1403.yaml (revision 833e5d42ab135b0238e61c5b3c19b8619677cbfa)
1*833e5d42SEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2*833e5d42SEmmanuel Vadot%YAML 1.2
3*833e5d42SEmmanuel Vadot---
4*833e5d42SEmmanuel Vadot$id: http://devicetree.org/schemas/gpio/exar,xra1403.yaml#
5*833e5d42SEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*833e5d42SEmmanuel Vadot
7*833e5d42SEmmanuel Vadottitle: XRA1403 16-bit GPIO Expander with Reset Input
8*833e5d42SEmmanuel Vadot
9*833e5d42SEmmanuel Vadotmaintainers:
10*833e5d42SEmmanuel Vadot  - Nandor Han <nandor.han@ge.com>
11*833e5d42SEmmanuel Vadot
12*833e5d42SEmmanuel Vadotdescription: >
13*833e5d42SEmmanuel Vadot  The XRA1403 is an 16-bit GPIO expander with an SPI interface. Features
14*833e5d42SEmmanuel Vadot  available:
15*833e5d42SEmmanuel Vadot
16*833e5d42SEmmanuel Vadot    - Individually programmable inputs:
17*833e5d42SEmmanuel Vadot        - Internal pull-up resistors
18*833e5d42SEmmanuel Vadot        - Polarity inversion
19*833e5d42SEmmanuel Vadot        - Individual interrupt enable
20*833e5d42SEmmanuel Vadot        - Rising edge and/or Falling edge interrupt
21*833e5d42SEmmanuel Vadot        - Input filter
22*833e5d42SEmmanuel Vadot    - Individually programmable outputs:
23*833e5d42SEmmanuel Vadot        - Output Level Control
24*833e5d42SEmmanuel Vadot        - Output Three-State Control
25*833e5d42SEmmanuel Vadot
26*833e5d42SEmmanuel Vadotproperties:
27*833e5d42SEmmanuel Vadot  compatible:
28*833e5d42SEmmanuel Vadot    const: exar,xra1403
29*833e5d42SEmmanuel Vadot
30*833e5d42SEmmanuel Vadot  reg:
31*833e5d42SEmmanuel Vadot    maxItems: 1
32*833e5d42SEmmanuel Vadot
33*833e5d42SEmmanuel Vadot  gpio-controller: true
34*833e5d42SEmmanuel Vadot
35*833e5d42SEmmanuel Vadot  '#gpio-cells':
36*833e5d42SEmmanuel Vadot    const: 2
37*833e5d42SEmmanuel Vadot
38*833e5d42SEmmanuel Vadot  interrupt-controller: true
39*833e5d42SEmmanuel Vadot
40*833e5d42SEmmanuel Vadot  '#interrupt-cells':
41*833e5d42SEmmanuel Vadot    const: 2
42*833e5d42SEmmanuel Vadot
43*833e5d42SEmmanuel Vadot  reset-gpios:
44*833e5d42SEmmanuel Vadot    description: Control line for the device reset.
45*833e5d42SEmmanuel Vadot
46*833e5d42SEmmanuel Vadotrequired:
47*833e5d42SEmmanuel Vadot  - compatible
48*833e5d42SEmmanuel Vadot  - reg
49*833e5d42SEmmanuel Vadot  - gpio-controller
50*833e5d42SEmmanuel Vadot  - '#gpio-cells'
51*833e5d42SEmmanuel Vadot
52*833e5d42SEmmanuel VadotallOf:
53*833e5d42SEmmanuel Vadot  - $ref: /schemas/spi/spi-peripheral-props.yaml#
54*833e5d42SEmmanuel Vadot
55*833e5d42SEmmanuel VadotunevaluatedProperties: false
56*833e5d42SEmmanuel Vadot
57*833e5d42SEmmanuel Vadotexamples:
58*833e5d42SEmmanuel Vadot  - |
59*833e5d42SEmmanuel Vadot    #include <dt-bindings/gpio/gpio.h>
60*833e5d42SEmmanuel Vadot
61*833e5d42SEmmanuel Vadot    spi {
62*833e5d42SEmmanuel Vadot        #address-cells = <1>;
63*833e5d42SEmmanuel Vadot        #size-cells = <0>;
64*833e5d42SEmmanuel Vadot
65*833e5d42SEmmanuel Vadot        gpio@2 {
66*833e5d42SEmmanuel Vadot            compatible = "exar,xra1403";
67*833e5d42SEmmanuel Vadot            reg = <2>;
68*833e5d42SEmmanuel Vadot            spi-max-frequency = <1000000>;
69*833e5d42SEmmanuel Vadot            gpio-controller;
70*833e5d42SEmmanuel Vadot            #gpio-cells = <2>;
71*833e5d42SEmmanuel Vadot            interrupt-controller;
72*833e5d42SEmmanuel Vadot            #interrupt-cells = <2>;
73*833e5d42SEmmanuel Vadot            reset-gpios = <&gpio3 6 GPIO_ACTIVE_LOW>;
74*833e5d42SEmmanuel Vadot        };
75*833e5d42SEmmanuel Vadot    };
76