From patchwork Sat Sep 13 09:26:51 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 4277 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-ej1-f70.google.com (mail-ej1-f70.google.com [209.85.218.70]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 2BDA93F16F for ; Sat, 13 Sep 2025 11:27:14 +0200 (CEST) Received: by mail-ej1-f70.google.com with SMTP id a640c23a62f3a-b07c292b885sf154438866b.0 for ; Sat, 13 Sep 2025 02:27:14 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1757755634; cv=pass; d=google.com; s=arc-20240605; b=F95wwiPAKIUeSZIYBIgrzivYHziZ8ZMu6IS1I1f8oUih9kVEljdRAGIsqv6VUEjMKE jtscn9x2s2So2qDv20lMnABReIlkD2mvhPJYTjchIk2eAVQvV3QAyME1U59aSYxVyUZW e5GtoVfZEY4RUR9FqXqkQD8W/VLDHw3v4Jpv1Xun2YNf5MQ5fM1bDKxnkYv1CSNy6ErP 1LwkRLLi0gQ7DAUO9GvkskqqXL02GMY2kTtzrK4EZQHPh/7V8Ay6nAtMYkrcJvPxhSkq l5FG5Z0UVEoC6s6nUBP0uNxZcEZUj31irQEI/GDb9f63LjUIgpmKMa5GPauIJs47uXFA CW1A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:message-id:date:subject:cc:to :from:dkim-signature; bh=NO/X+HoaaQVblKA7aLdnZHapNsXqf56wNKuf3bqvcuM=; fh=LeIiAtYph1UtTjRdIWhi9HtZZ55MjHX05VKU8LOHRK0=; b=KIf2usle9B3wbjcWy/7AWTSzjpfzbzpoZYnxY8MF0GbY+YChOV9y/JvNYS8Y3e0fOI 1fFU4dkl7pQavLUnOZna3FsNX8d1PQgqw/t9q66GgYGTbfhiBNRijoZJjUSOIqIwrk3K paDnpPuuw2/hdnfj4zWAOiVaQui+ljG7U6Cxl8OmcGC4BjMkNB+YAXWPgwBzKWsZ/5at FZxd9dt2QphWrRPw8KxNVbpUwj1HmEl8oGIe2N7FTzFLCFoX+XbZA1YzaZFGzu0Fy02h +0Kh+kBBzPOyAqkku9bUSUkdYws30BW9tZWRKf+spdnet9lETsfm4yE4fXtvwfvJQbCY c6NA==; darn=patchwork.amarulasolutions.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=i4IlHfqp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1757755634; x=1758360434; darn=patchwork.amarulasolutions.com; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:x-original-authentication-results :x-original-sender:mime-version:message-id:date:subject:cc:to:from :from:to:cc:subject:date:message-id:reply-to; bh=NO/X+HoaaQVblKA7aLdnZHapNsXqf56wNKuf3bqvcuM=; b=Jdd6rwStvR5ii91m+ygjwNaE/l/26+Pbrf2ITlIoyYCii7DOSPLjdVrMgwrQDb4OLE 82+2TYvca09QcKKa9L9Ez44Ng89+w1wSafICvg+VC7a14x/uMxQJXj3dPulH/mFnEHL7 Qp2sQ0X/TmLHW0uJ7DDBGgC658z1nnTNrdg2Y= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1757755634; x=1758360434; h=list-unsubscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence :x-original-authentication-results:x-original-sender:mime-version :message-id:date:subject:cc:to:from:x-beenthere:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=NO/X+HoaaQVblKA7aLdnZHapNsXqf56wNKuf3bqvcuM=; b=wYRYf1n8tBTDstVJyXsfr6ZMLlil3mRfsebwxWFpxvt9+R1EJrZONeUF/OIOQzHr5c jARh2rmq7punpZMC6ESfsj8vEpd0U+pEj9g9PjZWOqhaqK+kZmA1w+AAh2DtOoffeBj0 yzJ72eQUzO11vqRnp1TcZ7WqGqwUHjjdpglXry39L+sCkP/KA1QoJxWp6Po2kwW3+tJM e23h2smMiCG6mwcn7qM3JeVCwnOzMVNFISATugtxKUAGVoy+eUv5TH3DnJFtC74XWg3s 4FIzfCG0pCanufGy+Lmiw20GfQdz+hjQ7gO0QxzQeas68wacGGboyNcbEj7qngQdyG7m qhGg== X-Forwarded-Encrypted: i=2; AJvYcCVXD0iqE+d/FvpO0mj0BGNVMV49KchUYtrONgLrgo2jhxgE5lZbG8hb10M3O/Dh+KpvM7sH9kiAS1D0v+oK@patchwork.amarulasolutions.com X-Gm-Message-State: AOJu0YysQxIgdpcLqPAhR8AaemgjwigJ/q+/XMg2uyyqyqAeU86C9bxY RsXXFKcGod9UwsaHtcwEfKVQYqy54l86DB0ABvtnY2X5f++yL6XLloWjiE2GN6hgWHgsGA== X-Google-Smtp-Source: AGHT+IHPM99+9463avjbX0kqXFfGuL0xW5PgVTOnenbxw+GfS5DHYE74jYwmcZ4F86a9dJtd9FBLQA== X-Received: by 2002:a17:907:843:b0:b04:315c:8760 with SMTP id a640c23a62f3a-b07c3838a93mr542212566b.50.1757755633438; Sat, 13 Sep 2025 02:27:13 -0700 (PDT) X-BeenThere: linux-amarula@amarulasolutions.com; h=ARHlJd4SYG+9msTYcQGIyMZYA0HTxekgfWmKQF4CUf3NUYd4OA== Received: by 2002:a05:6402:4384:b0:61c:c9e2:e4c6 with SMTP id 4fb4d7f45d1cf-62eba37710als2310017a12.0.-pod-prod-01-eu; Sat, 13 Sep 2025 02:27:11 -0700 (PDT) X-Received: by 2002:a17:907:9694:b0:b04:6973:1ee9 with SMTP id a640c23a62f3a-b07c3570af8mr620833066b.16.1757755631009; Sat, 13 Sep 2025 02:27:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1757755631; cv=none; d=google.com; s=arc-20240605; b=b0DHFJYXfJzxyMyVUIhM2yQhBRM950QjZYyxg5Ju53sWLbVaBKKt5LqRl57DHri6AQ /cmaVIy4+qYaalCBLPB/D0+WTtLhsUi33VlU9ZRmu3njX5tcJ/RJiX3Kp0Eo+loTXJmq fhMTzm09cjeIs6IFVblwshMQdt2zld+NaFpLF0zaEQEATCqv3HFixY+L1BQWfC35cdBs /bqQ3VRpNRtQfmtD1wOBikMk185pqevlPUAXA0tNCsyAagC87YfO97Ku4Xtp3OzqKHi5 zXocrbCXyO7Um7tA4HxfBXZ0RvAsLf87Hsn5mSbRRuiheBkiFxOm/eb/hpVJMvqspsNo i9Pg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=sqXoJTPCt/TEsVffyq8j5TIAdrRKPjQJmGTKxR+1RTc=; fh=5IPoofO8fd847Zr+LJ+89nR9QZf+bxlD0HrxkhpH2D0=; b=jiMJCkeWvp69fJ4aeCbM7wj3xmEDd3eBdMh2nJZdHjhz15Zuit+23wlxWj6f7wACsD bDdKa4jhwgPIpZDiW5gfksNOe7SbD0qhhuyEHWub590MAHmGMJz5oZl0227k1Ya1FBcx 0fLiDbOtP7qvs54pInFKuiSaIDcq6ABcqRL5fGt/ZNlvm7Gil3GleY5PDigv01qML3Ll la+43MK0zq05UiCBlYzTJ3GEjVFyItkCQhgeY846+H4bT98Ftb2VFzjafCM/dUh5VIfV lyChBjxavT6vVcVnbH18cMyY+xu/PuiF2o4OAQI/gfcHFEG4A094fYO+xh8iCabRwR8X BVDg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=i4IlHfqp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Received: from mail-sor-f41.google.com (mail-sor-f41.google.com. [209.85.220.41]) by mx.google.com with SMTPS id a640c23a62f3a-b07b32a1956sor233391466b.12.2025.09.13.02.27.10 for (Google Transport Security); Sat, 13 Sep 2025 02:27:10 -0700 (PDT) Received-SPF: pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) client-ip=209.85.220.41; X-Gm-Gg: ASbGncto7ZZRuHAQsu2lJUwfyovJyN3dDNlIOUbXz2cV40COBWWYBrwQTZRIk9pjbRu tzU7J6NemhQZ4Oz0m9v6n3vF0v5QJiIVhT6ir1tZm7W9JYtLntXvNp5nLZtyVuyFDGZqIlvapn3 D1fuapOGiFLAEV32k6169AGSjaKQEhO8DomOIqOoTQEVQxfV+y+USmWbt3RQuOGfMk0/Pg0qEkT vxohFOQiFu4+Gwy8W/3m329NHLdfdMY2KaFhddCoib8geae/UsfUKmBShHwgrWzPDiclUSIygjR 4XlfAFk4AlKLzg/tqTTFfCQRBcRCrvkCP9VvMs6W6p93IInq8EZ0XsV/zlAmD2q5nuWs4b6hHs4 K7N2UFt47CAbQlwEIJ61iOfericYIL1qTKTT3z8OIGjzsJs84ny5cOd1XKJmqB4rK6EfVwXt0o3 DX0hd9llcj4BOo4fd5JSP/ntftneQIboA/k4edle2PDalh8MbS1tt288uG6FXnTRpH X-Received: by 2002:a17:907:daa:b0:b04:97a2:64f8 with SMTP id a640c23a62f3a-b07c3532805mr587574766b.2.1757755630506; Sat, 13 Sep 2025 02:27:10 -0700 (PDT) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-82-56-38-125.retail.telecomitalia.it. [82.56.38.125]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b07b33478besm551705766b.99.2025.09.13.02.27.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 13 Sep 2025 02:27:10 -0700 (PDT) From: Dario Binacchi To: linux-kernel@vger.kernel.org Cc: linux-amarula@amarulasolutions.com, Dario Binacchi , Conor Dooley , Dmitry Torokhov , Krzysztof Kozlowski , Rob Herring , devicetree@vger.kernel.org, linux-input@vger.kernel.org Subject: [PATCH v2 1/5] dt-bindings: touchscreen: convert bu21013 bindings to json schema Date: Sat, 13 Sep 2025 11:26:51 +0200 Message-ID: <20250913092707.1005616-1-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-Original-Sender: dario.binacchi@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=i4IlHfqp; spf=pass (google.com: domain of dario.binacchi@amarulasolutions.com designates 209.85.220.41 as permitted sender) smtp.mailfrom=dario.binacchi@amarulasolutions.com; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=amarulasolutions.com; dara=pass header.i=@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Convert Rohm BU21013 I2C touchscreen controller device tree binding to json-schema. Additional changes: - Replace -supply with avdd-supply to match example and existing DTS. - Add reset-gpios in the example because it is required. Signed-off-by: Dario Binacchi --- Changes in v2: - Added in v2 .../bindings/input/touchscreen/bu21013.txt | 43 --------- .../bindings/input/touchscreen/bu21013.yaml | 96 +++++++++++++++++++ 2 files changed, 96 insertions(+), 43 deletions(-) delete mode 100644 Documentation/devicetree/bindings/input/touchscreen/bu21013.txt create mode 100644 Documentation/devicetree/bindings/input/touchscreen/bu21013.yaml diff --git a/Documentation/devicetree/bindings/input/touchscreen/bu21013.txt b/Documentation/devicetree/bindings/input/touchscreen/bu21013.txt deleted file mode 100644 index da4c9d8b99b1..000000000000 --- a/Documentation/devicetree/bindings/input/touchscreen/bu21013.txt +++ /dev/null @@ -1,43 +0,0 @@ -* Rohm BU21013 Touch Screen - -Required properties: - - compatible : "rohm,bu21013_tp" - - reg : I2C device address - - reset-gpios : GPIO pin enabling (selecting) chip (CS) - - interrupt-parent : the phandle for the gpio controller - - interrupts : (gpio) interrupt to which the chip is connected - -Optional properties: - - touch-gpios : GPIO pin registering a touch event - - -supply : Phandle to a regulator supply - - touchscreen-size-x : General touchscreen binding, see [1]. - - touchscreen-size-y : General touchscreen binding, see [1]. - - touchscreen-inverted-x : General touchscreen binding, see [1]. - - touchscreen-inverted-y : General touchscreen binding, see [1]. - - touchscreen-swapped-x-y : General touchscreen binding, see [1]. - -[1] All general touchscreen properties are described in - Documentation/devicetree/bindings/input/touchscreen/touchscreen.txt. - -Deprecated properties: - - rohm,touch-max-x : Maximum outward permitted limit in the X axis - - rohm,touch-max-y : Maximum outward permitted limit in the Y axis - - rohm,flip-x : Flip touch coordinates on the X axis - - rohm,flip-y : Flip touch coordinates on the Y axis - -Example: - - i2c@80110000 { - bu21013_tp@5c { - compatible = "rohm,bu21013_tp"; - reg = <0x5c>; - interrupt-parent = <&gpio2>; - interrupts <&20 IRQ_TYPE_LEVEL_LOW>; - touch-gpio = <&gpio2 20 GPIO_ACTIVE_LOW>; - avdd-supply = <&ab8500_ldo_aux1_reg>; - - touchscreen-size-x = <384>; - touchscreen-size-y = <704>; - touchscreen-inverted-y; - }; - }; diff --git a/Documentation/devicetree/bindings/input/touchscreen/bu21013.yaml b/Documentation/devicetree/bindings/input/touchscreen/bu21013.yaml new file mode 100644 index 000000000000..aeb581fcaf29 --- /dev/null +++ b/Documentation/devicetree/bindings/input/touchscreen/bu21013.yaml @@ -0,0 +1,96 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/input/touchscreen/bu21013.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Rohm BU21013 touchscreen + +description: + Rohm BU21013 I2C driven touchscreen controller. + +maintainers: + - Dario Binacchi + +allOf: + - $ref: touchscreen.yaml# + +properties: + compatible: + enum: + - rohm,bu21013_tp + + reg: + maxItems: 1 + + interrupts: + maxItems: 1 + + reset-gpios: + maxItems: 1 + description: GPIO resetting the chip + + touch-gpios: + maxItems: 1 + description: GPIO registering a touch event. + + avdd-supply: + description: Phandle to the regulator supplying the analog circuit. + + rohm,touch-max-x: + deprecated: true + description: Maximum value on the X axis. + $ref: /schemas/types.yaml#/definitions/uint32 + + rohm,touch-max-y: + deprecated: true + description: Maximum value on the Y axis. + $ref: /schemas/types.yaml#/definitions/uint32 + + rohm,flip-x: + deprecated: true + description: Flip touch coordinates on the X axis + type: boolean + + rohm,flip-y: + deprecated: true + description: Flip touch coordinates on the Y axis + type: boolean + + touchscreen-inverted-x: true + touchscreen-inverted-y: true + touchscreen-size-x: true + touchscreen-size-y: true + touchscreen-swapped-x-y: true + +additionalProperties: false + +required: + - compatible + - reg + - reset-gpios + - interrupts + +examples: + - | + #include + #include + i2c { + #address-cells = <1>; + #size-cells = <0>; + + touchscreen@5c { + compatible = "rohm,bu21013_tp"; + reg = <0x5c>; + + interrupt-parent = <&gpio2>; + interrupts = <0x20 IRQ_TYPE_LEVEL_LOW>; + reset-gpios = <&gpio2 19 GPIO_ACTIVE_LOW>; + touch-gpios = <&gpio2 20 GPIO_ACTIVE_LOW>; + avdd-supply = <&ab8500_ldo_aux1_reg>; + + touchscreen-size-x = <384>; + touchscreen-size-y = <704>; + touchscreen-inverted-y; + }; + };