Devicetree
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: input: touchscreen: convert sis_i2c to DT schema
@ 2026-08-21 13:10 Ștefan Ghețu
  2026-08-21 13:33 ` Mika Penttilä
  2026-08-21 16:51 ` Conor Dooley
  0 siblings, 2 replies; 3+ messages in thread
From: Ștefan Ghețu @ 2026-08-21 13:10 UTC (permalink / raw)
  To: Mika Penttilä, Dmitry Torokhov, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: linux-input, devicetree, linux-kernel, Ștefan Ghețu

Convert the SiS 9200 family I2C touchscreen binding from free-form
text to DT schema format.

While at it, fix the example which referenced a non-existent
"irq-gpios" property; the driver looks up "attn" via
devm_gpiod_get_optional(), so the correct property is "attn-gpios".

Signed-off-by: Ștefan Ghețu <stefanghetu9@gmail.com>
---
 .../input/touchscreen/sis,9200-ts.yaml        | 61 +++++++++++++++++++
 .../bindings/input/touchscreen/sis_i2c.txt    | 31 ----------
 MAINTAINERS                                   |  2 +-
 3 files changed, 62 insertions(+), 32 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/input/touchscreen/sis,9200-ts.yaml
 delete mode 100644 Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt

diff --git a/Documentation/devicetree/bindings/input/touchscreen/sis,9200-ts.yaml b/Documentation/devicetree/bindings/input/touchscreen/sis,9200-ts.yaml
new file mode 100644
index 000000000..5c4806348
--- /dev/null
+++ b/Documentation/devicetree/bindings/input/touchscreen/sis,9200-ts.yaml
@@ -0,0 +1,61 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/input/touchscreen/sis,9200-ts.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: SiS 9200 Family I2C Touchscreen Controller
+
+maintainers:
+  - Mika Penttilä <mpenttil@redhat.com>
+
+allOf:
+  - $ref: touchscreen.yaml#
+
+properties:
+  compatible:
+    const: sis,9200-ts
+
+  reg:
+    maxItems: 1
+
+  interrupts:
+    maxItems: 1
+
+  attn-gpios:
+    maxItems: 1
+    description: GPIO pin used as the attention line
+
+  reset-gpios:
+    maxItems: 1
+    description: GPIO pin used to reset the controller
+
+  wakeup-source: true
+
+required:
+  - compatible
+  - reg
+  - interrupts
+
+unevaluatedProperties: false
+
+examples:
+  - |
+    #include <dt-bindings/gpio/gpio.h>
+    #include <dt-bindings/interrupt-controller/irq.h>
+
+    i2c {
+        #address-cells = <1>;
+        #size-cells = <0>;
+
+        touchscreen@5c {
+            compatible = "sis,9200-ts";
+            reg = <0x5c>;
+            pinctrl-names = "default";
+            pinctrl-0 = <&pinctrl_sis>;
+            interrupt-parent = <&gpio3>;
+            interrupts = <19 IRQ_TYPE_EDGE_FALLING>;
+            attn-gpios = <&gpio3 19 GPIO_ACTIVE_LOW>;
+            reset-gpios = <&gpio2 30 GPIO_ACTIVE_LOW>;
+        };
+    };
diff --git a/Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt b/Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt
deleted file mode 100644
index 8f5322e01..000000000
--- a/Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt
+++ /dev/null
@@ -1,31 +0,0 @@
-* SiS I2C Multiple Touch Controller
-
-Required properties:
-- compatible: must be "sis,9200-ts"
-- reg: i2c slave address
-- interrupts: touch controller interrupt (see interrupt
-  binding [0])
-
-Optional properties:
-- pinctrl-names: should be "default" (see pinctrl binding [1]).
-- pinctrl-0: a phandle pointing to the pin settings for the
-  device (see pinctrl binding [1]).
-- attn-gpios: the gpio pin used as attention line
-- reset-gpios: the gpio pin used to reset the controller
-- wakeup-source: touchscreen can be used as a wakeup source
-
-[0]: Documentation/devicetree/bindings/interrupt-controller/interrupts.txt
-[1]: Documentation/devicetree/bindings/pinctrl/pinctrl-bindings.txt
-
-Example:
-
-	sis9255@5c  {
-		compatible = "sis,9200-ts";
-		reg = <0x5c>;
-		pinctrl-names = "default";
-		pinctrl-0 = <&pinctrl_sis>;
-		interrupt-parent = <&gpio3>;
-		interrupts = <19 IRQ_TYPE_EDGE_FALLING>;
-		irq-gpios = <&gpio3 19 GPIO_ACTIVE_LOW>;
-		reset-gpios = <&gpio2 30 GPIO_ACTIVE_LOW>;
-	};
diff --git a/MAINTAINERS b/MAINTAINERS
index 8014b9f82..88d0cb1d8 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -24866,7 +24866,7 @@ SIS I2C TOUCHSCREEN DRIVER
 M:	Mika Penttilä <mpenttil@redhat.com>
 L:	linux-input@vger.kernel.org
 S:	Maintained
-F:	Documentation/devicetree/bindings/input/touchscreen/sis_i2c.txt
+F:	Documentation/devicetree/bindings/input/touchscreen/sis,9200-ts.yaml
 F:	drivers/input/touchscreen/sis_i2c.c
 
 SIS USB2VGA DRIVER
-- 
2.53.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-08-21 16:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-21 13:10 [PATCH] dt-bindings: input: touchscreen: convert sis_i2c to DT schema Ștefan Ghețu
2026-08-21 13:33 ` Mika Penttilä
2026-08-21 16:51 ` Conor Dooley

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox