diff mbox series

ARM: dts: stm32: add focaltech touchscreen on stm32mp157c-dk2 board

Message ID 1569854751-22337-1-git-send-email-yannick.fertre@st.com (mailing list archive)
State New, archived
Headers show
Series ARM: dts: stm32: add focaltech touchscreen on stm32mp157c-dk2 board | expand

Commit Message

Yannick FERTRE Sept. 30, 2019, 2:45 p.m. UTC
Enable focaltech ft6236 touchscreen on STM32MP157C-DK2 board.
This device supports 2 different addresses (0x2a and 0x38)
depending on the display  board version (MB1407).

Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
---
 arch/arm/boot/dts/stm32mp157c-dk2.dts | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

Comments

Alexandre TORGUE Oct. 3, 2019, 10:34 a.m. UTC | #1
Hi Yannick

On 9/30/19 4:45 PM, Yannick Fertré wrote:
> Enable focaltech ft6236 touchscreen on STM32MP157C-DK2 board.
> This device supports 2 different addresses (0x2a and 0x38)
> depending on the display  board version (MB1407).
> 
> Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
> ---
>   arch/arm/boot/dts/stm32mp157c-dk2.dts | 23 +++++++++++++++++++++++
>   1 file changed, 23 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/stm32mp157c-dk2.dts b/arch/arm/boot/dts/stm32mp157c-dk2.dts
> index 20ea601..527bb75 100644
> --- a/arch/arm/boot/dts/stm32mp157c-dk2.dts
> +++ b/arch/arm/boot/dts/stm32mp157c-dk2.dts
> @@ -61,6 +61,29 @@
>   	};
>   };
>   
> +&i2c1 {
> +	touchscreen@2a {
> +		compatible = "focaltech,ft6236";
> +		reg = <0x2a>;
> +		interrupts = <2 2>;
> +		interrupt-parent = <&gpiof>;
> +		interrupt-controller;
> +		touchscreen-size-x = <480>;
> +		touchscreen-size-y = <800>;
> +		status = "okay";
> +	};
> +	touchscreen@38 {
> +		compatible = "focaltech,ft6236";
> +		reg = <0x38>;
> +		interrupts = <2 2>;
> +		interrupt-parent = <&gpiof>;
> +		interrupt-controller;
> +		touchscreen-size-x = <480>;
> +		touchscreen-size-y = <800>;
> +		status = "okay";
> +	};
> +};

I'm not confident by this duplication. We should only support the latest 
revision of the MB1407. I understand the need but my fear is to 
duplicate this node each time we have a new revision (and imagine if we 
do that for all i2c devices).

regards
alex


>   &ltdc {
>   	status = "okay";
>   
>
Yannick FERTRE Oct. 4, 2019, 1:21 p.m. UTC | #2
Hi Alex,

ok, i'll push only the dt patch link to the last version of driver 
touchscreen on display board MB1407.

BR

Yannick Fertré


On 10/3/19 12:34 PM, Alexandre Torgue wrote:
> Hi Yannick
>
> On 9/30/19 4:45 PM, Yannick Fertré wrote:
>> Enable focaltech ft6236 touchscreen on STM32MP157C-DK2 board.
>> This device supports 2 different addresses (0x2a and 0x38)
>> depending on the display  board version (MB1407).
>>
>> Signed-off-by: Yannick Fertré <yannick.fertre@st.com>
>> ---
>>   arch/arm/boot/dts/stm32mp157c-dk2.dts | 23 +++++++++++++++++++++++
>>   1 file changed, 23 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/stm32mp157c-dk2.dts 
>> b/arch/arm/boot/dts/stm32mp157c-dk2.dts
>> index 20ea601..527bb75 100644
>> --- a/arch/arm/boot/dts/stm32mp157c-dk2.dts
>> +++ b/arch/arm/boot/dts/stm32mp157c-dk2.dts
>> @@ -61,6 +61,29 @@
>>       };
>>   };
>>   +&i2c1 {
>> +    touchscreen@2a {
>> +        compatible = "focaltech,ft6236";
>> +        reg = <0x2a>;
>> +        interrupts = <2 2>;
>> +        interrupt-parent = <&gpiof>;
>> +        interrupt-controller;
>> +        touchscreen-size-x = <480>;
>> +        touchscreen-size-y = <800>;
>> +        status = "okay";
>> +    };
>> +    touchscreen@38 {
>> +        compatible = "focaltech,ft6236";
>> +        reg = <0x38>;
>> +        interrupts = <2 2>;
>> +        interrupt-parent = <&gpiof>;
>> +        interrupt-controller;
>> +        touchscreen-size-x = <480>;
>> +        touchscreen-size-y = <800>;
>> +        status = "okay";
>> +    };
>> +};
>
> I'm not confident by this duplication. We should only support the 
> latest revision of the MB1407. I understand the need but my fear is to 
> duplicate this node each time we have a new revision (and imagine if 
> we do that for all i2c devices).
>
> regards
> alex
>
>
>>   &ltdc {
>>       status = "okay";
diff mbox series

Patch

diff --git a/arch/arm/boot/dts/stm32mp157c-dk2.dts b/arch/arm/boot/dts/stm32mp157c-dk2.dts
index 20ea601..527bb75 100644
--- a/arch/arm/boot/dts/stm32mp157c-dk2.dts
+++ b/arch/arm/boot/dts/stm32mp157c-dk2.dts
@@ -61,6 +61,29 @@ 
 	};
 };
 
+&i2c1 {
+	touchscreen@2a {
+		compatible = "focaltech,ft6236";
+		reg = <0x2a>;
+		interrupts = <2 2>;
+		interrupt-parent = <&gpiof>;
+		interrupt-controller;
+		touchscreen-size-x = <480>;
+		touchscreen-size-y = <800>;
+		status = "okay";
+	};
+	touchscreen@38 {
+		compatible = "focaltech,ft6236";
+		reg = <0x38>;
+		interrupts = <2 2>;
+		interrupt-parent = <&gpiof>;
+		interrupt-controller;
+		touchscreen-size-x = <480>;
+		touchscreen-size-y = <800>;
+		status = "okay";
+	};
+};
+
 &ltdc {
 	status = "okay";