summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/arm/vexpress-sysreg.yaml
blob: b5e26e41f88c8316f96a4a1a41b603a54d36f394 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/arm/vexpress-sysreg.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: ARM Versatile Express system registers bindings

maintainers:
  - Andre Przywara <andre.przywara@arm.com>

description:
  This is a system control registers block, providing multiple low level
  platform functions like board detection and identification, software
  interrupt generation, MMC and NOR Flash control, etc.

properties:
  compatible:
    const: arm,vexpress-sysreg

  reg:
    maxItems: 1

  "#address-cells":
    const: 1

  "#size-cells":
    const: 1

  ranges: true

additionalProperties: false

patternProperties:
  '^gpio@[0-9a-f]+$':
    type: object
    additionalProperties: false
    description:
      GPIO children

    properties:
      compatible:
        enum:
          - arm,vexpress-sysreg,sys_led
          - arm,vexpress-sysreg,sys_mci
          - arm,vexpress-sysreg,sys_flash

      gpio-controller: true

      "#gpio-cells":
        const: 2
        description: |
          The first cell is the function number:
          for sys_led : 0..7 = LED 0..7
          for sys_mci : 0 = MMC CARDIN, 1 = MMC WPROT
          for sys_flash : 0 = NOR FLASH WPn
          The second cell can take standard GPIO flags.

      reg:
        maxItems: 1

    required:
      - compatible
      - reg
      - gpio-controller
      - "#gpio-cells"

required:
  - compatible
  - "#address-cells"
  - "#size-cells"

examples:
  - |
    sysreg@0 {
        compatible = "arm,vexpress-sysreg";
        reg = <0x00000 0x1000>;
        #address-cells = <1>;
        #size-cells = <1>;
        ranges = <0 0 0x1000>;

        v2m_led_gpios: gpio@8 {
            compatible = "arm,vexpress-sysreg,sys_led";
            reg = <0x008 4>;
            gpio-controller;
            #gpio-cells = <2>;
        };
    };

...