dt-bindings: gpio: lsi,zevio-gpio: convert to dtschema
authorPratik Farkase <pratikfarkase94@gmail.com>
Wed, 22 May 2024 15:16:13 +0000 (17:16 +0200)
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Mon, 27 May 2024 14:52:45 +0000 (16:52 +0200)
Convert Zevio GPIO Controller from text to dtschema.
Adding `interrupts` property fixes the following warning:
linux/out/arch/arm/boot/dts/nspire/nspire-tp.dtb: gpio@90000000:
'interrupts' does not match any of the regexes: 'pinctrl-[0-9]+'`
while executing `make dtbs_check` on Texas Instruments
nspire boards.

Signed-off-by: Pratik Farkase <pratik.farkase@wsisweden.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Link: https://lore.kernel.org/r/20240522151616.27397-1-pratik.farkase@wsisweden.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Documentation/devicetree/bindings/gpio/gpio-zevio.txt [deleted file]
Documentation/devicetree/bindings/gpio/lsi,zevio-gpio.yaml [new file with mode: 0644]

diff --git a/Documentation/devicetree/bindings/gpio/gpio-zevio.txt b/Documentation/devicetree/bindings/gpio/gpio-zevio.txt
deleted file mode 100644 (file)
index a37bd9a..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-Zevio GPIO controller
-
-Required properties:
-- compatible: Should be "lsi,zevio-gpio"
-- reg: Address and length of the register set for the device
-- #gpio-cells: Should be two. The first cell is the pin number and the
-  second cell is used to specify optional parameters (currently unused).
-- gpio-controller: Marks the device node as a GPIO controller.
-
-Example:
-       gpio: gpio@90000000 {
-               compatible = "lsi,zevio-gpio";
-               reg = <0x90000000 0x1000>;
-               gpio-controller;
-               #gpio-cells = <2>;
-       };
diff --git a/Documentation/devicetree/bindings/gpio/lsi,zevio-gpio.yaml b/Documentation/devicetree/bindings/gpio/lsi,zevio-gpio.yaml
new file mode 100644 (file)
index 0000000..e9e201a
--- /dev/null
@@ -0,0 +1,43 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/gpio/lsi,zevio-gpio.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Zevio GPIO controller
+
+maintainers:
+  - Pratik Farkase <pratikfarkase94@gmail.com>
+
+properties:
+  compatible:
+    items:
+      - const: lsi,zevio-gpio
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  "#gpio-cells":
+    const: 2
+
+  gpio-controller: true
+
+required:
+  - compatible
+  - reg
+  - "#gpio-cells"
+  - gpio-controller
+
+unevaluatedProperties: false
+
+examples:
+  - |
+    gpio@90000000 {
+        compatible = "lsi,zevio-gpio";
+        reg = <0x90000000 0x1000>;
+        gpio-controller;
+        #gpio-cells = <2>;
+    };