1# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/interrupt-controller/st,stm32-exti.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: STM32 External Interrupt Controller Device Tree Bindings
8
9maintainers:
10  - Alexandre Torgue <alexandre.torgue@st.com>
11  - Ludovic Barre <ludovic.barre@st.com>
12
13properties:
14  compatible:
15    oneOf:
16      - items:
17        - enum:
18          - st,stm32-exti
19          - st,stm32h7-exti
20      - items:
21        - enum:
22          - st,stm32mp1-exti
23        - const: syscon
24
25  "#interrupt-cells":
26    const: 2
27
28  reg:
29    maxItems: 1
30
31  interrupt-controller: true
32
33  hwlocks:
34    maxItems: 1
35    description:
36      Reference to a phandle of a hardware spinlock provider node.
37
38  interrupts:
39    description:
40      Interrupts references to primary interrupt controller
41
42required:
43  - "#interrupt-cells"
44  - compatible
45  - reg
46  - interrupt-controller
47
48allOf:
49  - $ref: /schemas/interrupt-controller.yaml#
50  - if:
51      properties:
52        compatible:
53          contains:
54            enum:
55              - st,stm32-exti
56    then:
57      properties:
58        interrupts:
59          minItems: 1
60          maxItems: 32
61      required:
62        - interrupts
63  - if:
64      properties:
65        compatible:
66          contains:
67            enum:
68              - st,stm32h7-exti
69    then:
70      properties:
71        interrupts:
72          minItems: 1
73          maxItems: 96
74      required:
75        - interrupts
76
77additionalProperties: false
78
79examples:
80  - |
81    //Example 1
82    exti1: interrupt-controller@5000d000 {
83        compatible = "st,stm32mp1-exti", "syscon";
84        interrupt-controller;
85        #interrupt-cells = <2>;
86        reg = <0x5000d000 0x400>;
87    };
88
89    //Example 2
90    exti2: interrupt-controller@40013c00 {
91        compatible = "st,stm32-exti";
92        interrupt-controller;
93        #interrupt-cells = <2>;
94        reg = <0x40013C00 0x400>;
95        interrupts = <1>, <2>, <3>, <6>, <7>, <8>, <9>, <10>, <23>, <40>, <41>, <42>, <62>, <76>;
96    };
97
98...
99