Documentation / devicetree / bindings / gpio / airoha,en7523-gpio.yaml


Based on kernel version 6.11. Page generated on 2024-09-24 08:21 EST.

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
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/gpio/airoha,en7523-gpio.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Airoha EN7523 GPIO controller

maintainers:
  - John Crispin <john@phrozen.org>

description: |
  Airoha's GPIO controller on their ARM EN7523 SoCs consists of two banks of 32
  GPIOs.

properties:
  $nodename:
    pattern: "^gpio@[0-9a-f]+$"

  compatible:
    items:
      - const: airoha,en7523-gpio

  reg:
    description: |
      The first tuple points to the input register.
      The second and third tuple point to the direction registers
      The fourth tuple points to the output register
    maxItems: 4
 
  "#gpio-cells":
    const: 2

  gpio-controller: true

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

additionalProperties: false

examples:
  - |
    gpio0: gpio@1fbf0200 {
        compatible = "airoha,en7523-gpio";
        reg = <0x1fbf0204 0x4>,
              <0x1fbf0200 0x4>,
              <0x1fbf0220 0x4>,
              <0x1fbf0214 0x4>;
        gpio-controller;
        #gpio-cells = <2>;
    };

    gpio1: gpio@1fbf0270 {
        compatible = "airoha,en7523-gpio";
        reg = <0x1fbf0270 0x4>,
              <0x1fbf0260 0x4>,
              <0x1fbf0264 0x4>,
              <0x1fbf0278 0x4>;
        gpio-controller;
        #gpio-cells = <2>;
    };
 
...