* [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend
[not found] <20201104153032.1387747-1-linus.walleij@linaro.org>
@ 2020-11-04 15:30 ` Linus Walleij
2020-11-09 17:30 ` Rob Herring
2020-11-23 6:48 ` Dmitry Torokhov
0 siblings, 2 replies; 3+ messages in thread
From: Linus Walleij @ 2020-11-04 15:30 UTC (permalink / raw)
To: Dmitry Torokhov, linux-input
Cc: Linus Walleij, Nick Dyer, Stephan Gerhold, devicetree
This converts the Armel MXT touchscreen bindings to YAML
format and extends them with the following two properties:
- vdda-supply: the optional analog supply voltage
- vdd-supply: the optional digital supply voltage
I also explained about the reset-gpios property that this
better be flagged as active high (0) despite actually
being active low, because all current device trees and
drivers assume that this is the case and will actively
drive the line low to assert RESET.
Tested the schema with all in-tree users and they verify
fine.
Cc: Nick Dyer <nick@shmanahar.org>
Cc: Stephan Gerhold <stephan@gerhold.net>
Cc: devicetree@vger.kernel.org
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
---
ChangeLog v1->v2:
- State that the GPIO lines shall be flagged as active low.
We will fix all users.
---
.../bindings/input/atmel,maxtouch.txt | 41 ----------
.../bindings/input/atmel,maxtouch.yaml | 81 +++++++++++++++++++
MAINTAINERS | 2 +-
3 files changed, 82 insertions(+), 42 deletions(-)
delete mode 100644 Documentation/devicetree/bindings/input/atmel,maxtouch.txt
create mode 100644 Documentation/devicetree/bindings/input/atmel,maxtouch.yaml
diff --git a/Documentation/devicetree/bindings/input/atmel,maxtouch.txt b/Documentation/devicetree/bindings/input/atmel,maxtouch.txt
deleted file mode 100644
index c88919480d37..000000000000
--- a/Documentation/devicetree/bindings/input/atmel,maxtouch.txt
+++ /dev/null
@@ -1,41 +0,0 @@
-Atmel maXTouch touchscreen/touchpad
-
-Required properties:
-- compatible:
- atmel,maxtouch
-
- The following compatibles have been used in various products but are
- deprecated:
- atmel,qt602240_ts
- atmel,atmel_mxt_ts
- atmel,atmel_mxt_tp
- atmel,mXT224
-
-- reg: The I2C address of the device
-
-- interrupts: The sink for the touchpad's IRQ output
- See ../interrupt-controller/interrupts.txt
-
-Optional properties for main touchpad device:
-
-- linux,gpio-keymap: When enabled, the SPT_GPIOPWN_T19 object sends messages
- on GPIO bit changes. An array of up to 8 entries can be provided
- indicating the Linux keycode mapped to each bit of the status byte,
- starting at the LSB. Linux keycodes are defined in
- <dt-bindings/input/input.h>.
-
- Note: the numbering of the GPIOs and the bit they start at varies between
- maXTouch devices. You must either refer to the documentation, or
- experiment to determine which bit corresponds to which input. Use
- KEY_RESERVED for unused padding values.
-
-- reset-gpios: GPIO specifier for the touchscreen's reset pin (active low)
-
-Example:
-
- touch@4b {
- compatible = "atmel,maxtouch";
- reg = <0x4b>;
- interrupt-parent = <&gpio>;
- interrupts = <TEGRA_GPIO(W, 3) IRQ_TYPE_LEVEL_LOW>;
- };
diff --git a/Documentation/devicetree/bindings/input/atmel,maxtouch.yaml b/Documentation/devicetree/bindings/input/atmel,maxtouch.yaml
new file mode 100644
index 000000000000..8c6418f76e94
--- /dev/null
+++ b/Documentation/devicetree/bindings/input/atmel,maxtouch.yaml
@@ -0,0 +1,81 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/input/atmel,maxtouch.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Atmel maXTouch touchscreen/touchpad
+
+maintainers:
+ - Nick Dyer <nick@shmanahar.org>
+ - Linus Walleij <linus.walleij@linaro.org>
+
+description: |
+ Atmel maXTouch touchscreen or touchpads such as the mXT244
+ and similar devices.
+
+properties:
+ compatible:
+ const: atmel,maxtouch
+
+ reg:
+ maxItems: 1
+
+ interrupts:
+ maxItems: 1
+
+ vdda-supply:
+ description:
+ Optional regulator for the AVDD analog voltage.
+
+ vdd-supply:
+ description:
+ Optional regulator for the VDD digital voltage.
+
+ reset-gpios:
+ maxItems: 1
+ description:
+ Optional GPIO specifier for the touchscreen's reset pin
+ (active low). The line must be flagged with
+ GPIO_ACTIVE_LOW.
+
+ linux,gpio-keymap:
+ $ref: /schemas/types.yaml#/definitions/uint32-array
+ description: |
+ When enabled, the SPT_GPIOPWN_T19 object sends messages
+ on GPIO bit changes. An array of up to 8 entries can be provided
+ indicating the Linux keycode mapped to each bit of the status byte,
+ starting at the LSB. Linux keycodes are defined in
+ <dt-bindings/input/input.h>.
+
+ Note: the numbering of the GPIOs and the bit they start at varies
+ between maXTouch devices. You must either refer to the documentation,
+ or experiment to determine which bit corresponds to which input. Use
+ KEY_RESERVED for unused padding values.
+
+required:
+ - compatible
+ - reg
+ - interrupts
+
+additionalProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/interrupt-controller/irq.h>
+ #include <dt-bindings/gpio/gpio.h>
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ touchscreen@4a {
+ compatible = "atmel,maxtouch";
+ reg = <0x4a>;
+ interrupt-parent = <&gpio>;
+ interrupts = <26 IRQ_TYPE_EDGE_FALLING>;
+ reset-gpios = <&gpio 27 GPIO_ACTIVE_LOW>;
+ vdda-supply = <&ab8500_ldo_aux2_reg>;
+ vdd-supply = <&ab8500_ldo_aux5_reg>;
+ };
+ };
+
+...
diff --git a/MAINTAINERS b/MAINTAINERS
index e73636b75f29..b4b46fcb82db 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2966,7 +2966,7 @@ ATMEL MAXTOUCH DRIVER
M: Nick Dyer <nick@shmanahar.org>
S: Maintained
T: git git://github.com/ndyer/linux.git
-F: Documentation/devicetree/bindings/input/atmel,maxtouch.txt
+F: Documentation/devicetree/bindings/input/atmel,maxtouch.yaml
F: drivers/input/touchscreen/atmel_mxt_ts.c
ATMEL WIRELESS DRIVER
--
2.26.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend
2020-11-04 15:30 ` [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend Linus Walleij
@ 2020-11-09 17:30 ` Rob Herring
2020-11-23 6:48 ` Dmitry Torokhov
1 sibling, 0 replies; 3+ messages in thread
From: Rob Herring @ 2020-11-09 17:30 UTC (permalink / raw)
To: Linus Walleij
Cc: linux-input, Dmitry Torokhov, devicetree, Stephan Gerhold,
Nick Dyer
On Wed, 04 Nov 2020 16:30:31 +0100, Linus Walleij wrote:
> This converts the Armel MXT touchscreen bindings to YAML
> format and extends them with the following two properties:
>
> - vdda-supply: the optional analog supply voltage
> - vdd-supply: the optional digital supply voltage
>
> I also explained about the reset-gpios property that this
> better be flagged as active high (0) despite actually
> being active low, because all current device trees and
> drivers assume that this is the case and will actively
> drive the line low to assert RESET.
>
> Tested the schema with all in-tree users and they verify
> fine.
>
> Cc: Nick Dyer <nick@shmanahar.org>
> Cc: Stephan Gerhold <stephan@gerhold.net>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> ---
> ChangeLog v1->v2:
> - State that the GPIO lines shall be flagged as active low.
> We will fix all users.
> ---
> .../bindings/input/atmel,maxtouch.txt | 41 ----------
> .../bindings/input/atmel,maxtouch.yaml | 81 +++++++++++++++++++
> MAINTAINERS | 2 +-
> 3 files changed, 82 insertions(+), 42 deletions(-)
> delete mode 100644 Documentation/devicetree/bindings/input/atmel,maxtouch.txt
> create mode 100644 Documentation/devicetree/bindings/input/atmel,maxtouch.yaml
>
Reviewed-by: Rob Herring <robh@kernel.org>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend
2020-11-04 15:30 ` [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend Linus Walleij
2020-11-09 17:30 ` Rob Herring
@ 2020-11-23 6:48 ` Dmitry Torokhov
1 sibling, 0 replies; 3+ messages in thread
From: Dmitry Torokhov @ 2020-11-23 6:48 UTC (permalink / raw)
To: Linus Walleij; +Cc: linux-input, Nick Dyer, Stephan Gerhold, devicetree
On Wed, Nov 04, 2020 at 04:30:31PM +0100, Linus Walleij wrote:
> This converts the Armel MXT touchscreen bindings to YAML
> format and extends them with the following two properties:
>
> - vdda-supply: the optional analog supply voltage
> - vdd-supply: the optional digital supply voltage
>
> I also explained about the reset-gpios property that this
> better be flagged as active high (0) despite actually
> being active low, because all current device trees and
> drivers assume that this is the case and will actively
> drive the line low to assert RESET.
>
> Tested the schema with all in-tree users and they verify
> fine.
>
> Cc: Nick Dyer <nick@shmanahar.org>
> Cc: Stephan Gerhold <stephan@gerhold.net>
> Cc: devicetree@vger.kernel.org
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Applied, thank you.
--
Dmitry
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-11-23 6:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20201104153032.1387747-1-linus.walleij@linaro.org>
2020-11-04 15:30 ` [PATCH 2/3 v2] Input: atmel_mxt_ts - Convert bindings to YAML and extend Linus Walleij
2020-11-09 17:30 ` Rob Herring
2020-11-23 6:48 ` Dmitry Torokhov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).