2024-01-25 17:09:08

by Kamel BOUHARA

[permalink] [raw]
Subject: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

Add the TouchNetix axiom I2C touchscreen device tree bindings
documentation.

Signed-off-by: Kamel Bouhara <[email protected]>
---
.../input/touchscreen/touchnetix,ax54a.yaml | 67 +++++++++++++++++++
MAINTAINERS | 6 ++
2 files changed, 73 insertions(+)
create mode 100644 Documentation/devicetree/bindings/input/touchscreen/touchnetix,ax54a.yaml

diff --git a/Documentation/devicetree/bindings/input/touchscreen/touchnetix,ax54a.yaml b/Documentation/devicetree/bindings/input/touchscreen/touchnetix,ax54a.yaml
new file mode 100644
index 000000000000..7b3997457fa5
--- /dev/null
+++ b/Documentation/devicetree/bindings/input/touchscreen/touchnetix,ax54a.yaml
@@ -0,0 +1,67 @@
+# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/input/touchscreen/touchnetix,ax54a.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: TouchNetix Axiom series touchscreen controller
+
+maintainers:
+ - Kamel Bouhara <[email protected]>
+
+allOf:
+ - $ref: /schemas/input/touchscreen/touchscreen.yaml#
+ - $ref: /schemas/input/input.yaml#
+
+properties:
+ compatible:
+ const: touchnetix,ax54a
+
+ reg:
+ const: 0x66
+
+ interrupts:
+ maxItems: 1
+
+ reset-gpios:
+ maxItems: 1
+
+ vdda-supply:
+ description: Analog power supply regulator on VDDA pin
+
+ vddi-supply:
+ description: I/O power supply regulator on VDDI pin
+
+ startup-time-ms:
+ description: delay after power supply regulator is applied in ms
+
+required:
+ - compatible
+ - reg
+ - vdda-supply
+ - vddi-supply
+ - startup-time-ms
+
+unevaluatedProperties: false
+
+examples:
+ - |
+ #include <dt-bindings/gpio/gpio.h>
+ #include <dt-bindings/interrupt-controller/arm-gic.h>
+ i2c {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ touchscreen@66 {
+ compatible = "touchnetix,ax54a";
+ reg = <0x66>;
+ interrupt-parent = <&gpio2>;
+ interrupts = <2 IRQ_TYPE_EDGE_FALLING>;
+ reset-gpios = <&gpio1 1 GPIO_ACTIVE_HIGH>;
+ vdda-supply = <&vdda_reg>;
+ vddi-supply = <&vddi_reg>;
+ poll-interval = <20>;
+ startup-time-ms = <100>;
+ };
+ };
+...
diff --git a/MAINTAINERS b/MAINTAINERS
index 7608b714653f..4752d8436dbb 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -21431,6 +21431,12 @@ S: Maintained
F: Documentation/ABI/testing/sysfs-class-firmware-attributes
F: drivers/platform/x86/think-lmi.?

+TOUCHNETIX AXIOM I2C TOUCHSCREEN DRIVER
+M: Kamel Bouhara <[email protected]>
+L: [email protected]
+S: Maintained
+F: Documentation/devicetree/bindings/input/touchscreen/touchnetix,ax54a.yaml
+
THUNDERBOLT DMA TRAFFIC TEST DRIVER
M: Isaac Hazan <[email protected]>
L: [email protected]
--
2.25.1



2024-01-26 11:47:19

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

On 25/01/2024 17:58, Kamel Bouhara wrote:
> + reset-gpios:
> + maxItems: 1
> +
> + vdda-supply:
> + description: Analog power supply regulator on VDDA pin
> +
> + vddi-supply:
> + description: I/O power supply regulator on VDDI pin
> +
> + startup-time-ms:
> + description: delay after power supply regulator is applied in ms

That's a regulator property - ramp up time.

Best regards,
Krzysztof


2024-01-30 22:28:56

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

On Fri, Jan 26, 2024 at 12:46:16PM +0100, Krzysztof Kozlowski wrote:
> On 25/01/2024 17:58, Kamel Bouhara wrote:
> > + reset-gpios:
> > + maxItems: 1
> > +
> > + vdda-supply:
> > + description: Analog power supply regulator on VDDA pin
> > +
> > + vddi-supply:
> > + description: I/O power supply regulator on VDDI pin
> > +
> > + startup-time-ms:
> > + description: delay after power supply regulator is applied in ms
>
> That's a regulator property - ramp up time.

I'm sure there's an existing property name that could be used.

But why is it needed? Is it variable per board with the same device? If
not, it should be implied by the compatible.

Rob

2024-01-31 07:28:58

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

On 30/01/2024 23:28, Rob Herring wrote:
> On Fri, Jan 26, 2024 at 12:46:16PM +0100, Krzysztof Kozlowski wrote:
>> On 25/01/2024 17:58, Kamel Bouhara wrote:
>>> + reset-gpios:
>>> + maxItems: 1
>>> +
>>> + vdda-supply:
>>> + description: Analog power supply regulator on VDDA pin
>>> +
>>> + vddi-supply:
>>> + description: I/O power supply regulator on VDDI pin
>>> +
>>> + startup-time-ms:
>>> + description: delay after power supply regulator is applied in ms
>>
>> That's a regulator property - ramp up time.
>
> I'm sure there's an existing property name that could be used.
>
> But why is it needed? Is it variable per board with the same device? If
> not, it should be implied by the compatible.

I meant, that regulators have such property. Unless this is coming from
the device needs, not from the regulator?

Best regards,
Krzysztof


2024-01-31 09:12:09

by Kamel BOUHARA

[permalink] [raw]
Subject: Re: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

Hello,

On Wed, Jan 31, 2024 at 08:28:43AM +0100, Krzysztof Kozlowski wrote:
> On 30/01/2024 23:28, Rob Herring wrote:
> > On Fri, Jan 26, 2024 at 12:46:16PM +0100, Krzysztof Kozlowski wrote:
> >> On 25/01/2024 17:58, Kamel Bouhara wrote:
> >>> + reset-gpios:
> >>> + maxItems: 1
> >>> +
> >>> + vdda-supply:
> >>> + description: Analog power supply regulator on VDDA pin
> >>> +
> >>> + vddi-supply:
> >>> + description: I/O power supply regulator on VDDI pin
> >>> +
> >>> + startup-time-ms:
> >>> + description: delay after power supply regulator is applied in ms
> >>
> >> That's a regulator property - ramp up time.
> >
> > I'm sure there's an existing property name that could be used.
> >
> > But why is it needed? Is it variable per board with the same device? If
> > not, it should be implied by the compatible.
>
> I meant, that regulators have such property. Unless this is coming from
> the device needs, not from the regulator?
>

After looking again into the device's datasheet [1], the delay (startup
time) is not really optional and it shouldn't be set through devicetree.

IIUC, it have to be set unconditionally after a device reset or
a vdda assertion.

[1]: https://www.touchnetix.com/media/dgnjohor/tnxd00394-a3-axiom_ax54a_2d_touch_controller_datasheet.pdf
--
Kamel Bouhara, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com


2024-01-31 11:47:52

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v6 2/3] dt-bindings: input: Add TouchNetix axiom touchscreen

On 31/01/2024 10:06, Kamel Bouhara wrote:
> Hello,
>
> On Wed, Jan 31, 2024 at 08:28:43AM +0100, Krzysztof Kozlowski wrote:
>> On 30/01/2024 23:28, Rob Herring wrote:
>>> On Fri, Jan 26, 2024 at 12:46:16PM +0100, Krzysztof Kozlowski wrote:
>>>> On 25/01/2024 17:58, Kamel Bouhara wrote:
>>>>> + reset-gpios:
>>>>> + maxItems: 1
>>>>> +
>>>>> + vdda-supply:
>>>>> + description: Analog power supply regulator on VDDA pin
>>>>> +
>>>>> + vddi-supply:
>>>>> + description: I/O power supply regulator on VDDI pin
>>>>> +
>>>>> + startup-time-ms:
>>>>> + description: delay after power supply regulator is applied in ms
>>>>
>>>> That's a regulator property - ramp up time.
>>>
>>> I'm sure there's an existing property name that could be used.
>>>
>>> But why is it needed? Is it variable per board with the same device? If
>>> not, it should be implied by the compatible.
>>
>> I meant, that regulators have such property. Unless this is coming from
>> the device needs, not from the regulator?
>>
>
> After looking again into the device's datasheet [1], the delay (startup
> time) is not really optional and it shouldn't be set through devicetree.
>
> IIUC, it have to be set unconditionally after a device reset or
> a vdda assertion.
>
> [1]: https://www.touchnetix.com/media/dgnjohor/tnxd00394-a3-axiom_ax54a_2d_touch_controller_datasheet.pdf
> --

OK, then it's not a regulator ramp up, but rather part of device driver
(deduced from compatible).

Best regards,
Krzysztof