devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] Describe more hardware of the HTC One (M8)
@ 2025-10-07  5:55 Alexandre Messier via B4 Relay
  2025-10-07  5:55 ` [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs Alexandre Messier via B4 Relay
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Alexandre Messier via B4 Relay @ 2025-10-07  5:55 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel,
	Alexandre Messier

Add hardware description for these parts of the HTC One (M8):

 - Notification LEDs
 - Bluetooth
 - NFC
 - Touchscreen

Signed-off-by: Alexandre Messier <alex@me.ssier.org>
---
Alexandre Messier (4):
      ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
      ARM: dts: qcom: msm8974pro-htc-m8: add NFC support
      ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins
      ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen

 arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 88 +++++++++++++++++++++--
 1 file changed, 84 insertions(+), 4 deletions(-)
---
base-commit: e5f0a698b34ed76002dc5cff3804a61c80233a7a
change-id: 20251007-m8-dts-additions-ac20291afa24

Best regards,
-- 
Alexandre Messier <alex@me.ssier.org>



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

* [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-07  5:55 [PATCH 0/4] Describe more hardware of the HTC One (M8) Alexandre Messier via B4 Relay
@ 2025-10-07  5:55 ` Alexandre Messier via B4 Relay
  2025-10-07 10:03   ` Konrad Dybcio
  2025-10-07  5:55 ` [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support Alexandre Messier via B4 Relay
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier via B4 Relay @ 2025-10-07  5:55 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel,
	Alexandre Messier

From: Alexandre Messier <alex@me.ssier.org>

Add support for the notification LEDs on the HTC One M8.

Two LEDs are available, one amber and one green.

Signed-off-by: Alexandre Messier <alex@me.ssier.org>
---
 arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)

diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
index b896cc1ad6f7..9c3859069aba 100644
--- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
+++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
@@ -3,6 +3,7 @@
 #include "pm8841.dtsi"
 #include "pm8941.dtsi"
 #include <dt-bindings/input/input.h>
+#include <dt-bindings/leds/common.h>
 
 / {
 	model = "HTC One (M8)";
@@ -64,6 +65,24 @@ vreg_vph_pwr: vreg-vph-pwr {
 	};
 };
 
+&pm8941_lpg {
+	qcom,power-source = <1>;
+
+	status = "okay";
+
+	led@6 {
+		reg = <6>;
+		color = <LED_COLOR_ID_GREEN>;
+		function = LED_FUNCTION_STATUS;
+	};
+
+	led@7 {
+		reg = <7>;
+		color = <LED_COLOR_ID_AMBER>;
+		function = LED_FUNCTION_STATUS;
+	};
+};
+
 &pm8941_vib {
 	status = "okay";
 };

-- 
2.51.0



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

* [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support
  2025-10-07  5:55 [PATCH 0/4] Describe more hardware of the HTC One (M8) Alexandre Messier via B4 Relay
  2025-10-07  5:55 ` [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs Alexandre Messier via B4 Relay
@ 2025-10-07  5:55 ` Alexandre Messier via B4 Relay
  2025-10-07 10:03   ` Konrad Dybcio
  2025-10-07  5:55 ` [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins Alexandre Messier via B4 Relay
  2025-10-07  5:55 ` [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen Alexandre Messier via B4 Relay
  3 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier via B4 Relay @ 2025-10-07  5:55 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel,
	Alexandre Messier

From: Alexandre Messier <alex@me.ssier.org>

Add the NFC chip used in the HTC One M8 to its device tree.

Signed-off-by: Alexandre Messier <alex@me.ssier.org>
---
 arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
index 9c3859069aba..4026d6fedfbe 100644
--- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
+++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
@@ -65,6 +65,22 @@ vreg_vph_pwr: vreg-vph-pwr {
 	};
 };
 
+&blsp1_i2c3 {
+	clock-frequency = <384000>;
+
+	status = "okay";
+
+	nfc@28 {
+		compatible = "nxp,pn544-i2c";
+		reg = <0x28>;
+
+		interrupts-extended = <&tlmm 144 IRQ_TYPE_LEVEL_HIGH>;
+
+		enable-gpios = <&tlmm 2 GPIO_ACTIVE_LOW>;
+		firmware-gpios = <&tlmm 3 GPIO_ACTIVE_HIGH>;
+	};
+};
+
 &pm8941_lpg {
 	qcom,power-source = <1>;
 

-- 
2.51.0



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

* [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins
  2025-10-07  5:55 [PATCH 0/4] Describe more hardware of the HTC One (M8) Alexandre Messier via B4 Relay
  2025-10-07  5:55 ` [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs Alexandre Messier via B4 Relay
  2025-10-07  5:55 ` [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support Alexandre Messier via B4 Relay
@ 2025-10-07  5:55 ` Alexandre Messier via B4 Relay
  2025-10-07 10:05   ` Konrad Dybcio
  2025-10-07  5:55 ` [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen Alexandre Messier via B4 Relay
  3 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier via B4 Relay @ 2025-10-07  5:55 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel,
	Alexandre Messier

From: Alexandre Messier <alex@me.ssier.org>

Add the required pin configuration to enable Bluetooth.

Signed-off-by: Alexandre Messier <alex@me.ssier.org>
---
 arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
index 4026d6fedfbe..36eb42f0f3d9 100644
--- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
+++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
@@ -359,10 +359,19 @@ cmd-data-pins {
 	};
 
 	wcnss_pin_a: wcnss-pin-active-state {
-		pins = "gpio36", "gpio37", "gpio38", "gpio39", "gpio40";
-		function = "wlan";
-		drive-strength = <6>;
-		bias-pull-down;
+		bt-pins {
+			pins = "gpio35", "gpio43", "gpio44";
+			function = "bt";
+			drive-strength = <2>;
+			bias-pull-down;
+		};
+
+		wlan-pins {
+			pins = "gpio36", "gpio37", "gpio38", "gpio39", "gpio40";
+			function = "wlan";
+			drive-strength = <6>;
+			bias-pull-down;
+		};
 	};
 };
 

-- 
2.51.0



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

* [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen
  2025-10-07  5:55 [PATCH 0/4] Describe more hardware of the HTC One (M8) Alexandre Messier via B4 Relay
                   ` (2 preceding siblings ...)
  2025-10-07  5:55 ` [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins Alexandre Messier via B4 Relay
@ 2025-10-07  5:55 ` Alexandre Messier via B4 Relay
  2025-10-07 10:04   ` Konrad Dybcio
  3 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier via B4 Relay @ 2025-10-07  5:55 UTC (permalink / raw)
  To: Bjorn Andersson, Konrad Dybcio, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel,
	Alexandre Messier

From: Alexandre Messier <alex@me.ssier.org>

Add the touchscreen device node for the HTC One (M8).

Signed-off-by: Alexandre Messier <alex@me.ssier.org>
---
 arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 36 +++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
index 36eb42f0f3d9..040a256f9465 100644
--- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
+++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
@@ -65,6 +65,35 @@ vreg_vph_pwr: vreg-vph-pwr {
 	};
 };
 
+&blsp1_i2c2 {
+	clock-frequency = <384000>;
+
+	status = "okay";
+
+	touch@20 {
+		compatible = "syna,rmi4-i2c";
+		reg = <0x20>;
+
+		interrupts-extended = <&tlmm 18 IRQ_TYPE_LEVEL_LOW>;
+
+		pinctrl-0 = <&ts_int_pin>;
+		pinctrl-names = "default";
+
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		rmi4-f01@1 {
+			reg = <0x1>;
+			syna,nosleep-mode = <1>;
+		};
+
+		rmi4-f11@11 {
+			reg = <0x11>;
+			syna,sensor-type = <1>;
+		};
+	};
+};
+
 &blsp1_i2c3 {
 	clock-frequency = <384000>;
 
@@ -358,6 +387,13 @@ cmd-data-pins {
 		};
 	};
 
+	ts_int_pin: ts-int-pin-state {
+		pins = "gpio18";
+		function = "gpio";
+		drive-strength = <2>;
+		bias-disable;
+	};
+
 	wcnss_pin_a: wcnss-pin-active-state {
 		bt-pins {
 			pins = "gpio35", "gpio43", "gpio44";

-- 
2.51.0



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

* Re: [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-07  5:55 ` [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs Alexandre Messier via B4 Relay
@ 2025-10-07 10:03   ` Konrad Dybcio
  2025-10-12  6:03     ` Alexandre Messier
  0 siblings, 1 reply; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-07 10:03 UTC (permalink / raw)
  To: alex, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
> From: Alexandre Messier <alex@me.ssier.org>
> 
> Add support for the notification LEDs on the HTC One M8.
> 
> Two LEDs are available, one amber and one green.

Do they form a single notification led, or are they supposed
to act separately?

Konrad


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

* Re: [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support
  2025-10-07  5:55 ` [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support Alexandre Messier via B4 Relay
@ 2025-10-07 10:03   ` Konrad Dybcio
  0 siblings, 0 replies; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-07 10:03 UTC (permalink / raw)
  To: alex, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
> From: Alexandre Messier <alex@me.ssier.org>
> 
> Add the NFC chip used in the HTC One M8 to its device tree.
> 
> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
> ---
>  arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 16 ++++++++++++++++
>  1 file changed, 16 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> index 9c3859069aba..4026d6fedfbe 100644
> --- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> +++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> @@ -65,6 +65,22 @@ vreg_vph_pwr: vreg-vph-pwr {
>  	};
>  };
>  
> +&blsp1_i2c3 {
> +	clock-frequency = <384000>;

This is not a valid I2C frequency

Konrad

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

* Re: [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen
  2025-10-07  5:55 ` [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen Alexandre Messier via B4 Relay
@ 2025-10-07 10:04   ` Konrad Dybcio
  2025-10-09  5:50     ` Alexandre Messier
  0 siblings, 1 reply; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-07 10:04 UTC (permalink / raw)
  To: alex, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
> From: Alexandre Messier <alex@me.ssier.org>
> 
> Add the touchscreen device node for the HTC One (M8).
> 
> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
> ---
>  arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 36 +++++++++++++++++++++++
>  1 file changed, 36 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> index 36eb42f0f3d9..040a256f9465 100644
> --- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> +++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
> @@ -65,6 +65,35 @@ vreg_vph_pwr: vreg-vph-pwr {
>  	};
>  };
>  
> +&blsp1_i2c2 {
> +	clock-frequency = <384000>;

This is not a valid I2C frequency

You're looking for 100/400/1000 kHz

Konrad



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

* Re: [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins
  2025-10-07  5:55 ` [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins Alexandre Messier via B4 Relay
@ 2025-10-07 10:05   ` Konrad Dybcio
  0 siblings, 0 replies; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-07 10:05 UTC (permalink / raw)
  To: alex, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
> From: Alexandre Messier <alex@me.ssier.org>
> 
> Add the required pin configuration to enable Bluetooth.
> 
> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
> ---

Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>

Konrad

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

* Re: [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen
  2025-10-07 10:04   ` Konrad Dybcio
@ 2025-10-09  5:50     ` Alexandre Messier
  2025-10-09  9:30       ` Konrad Dybcio
  0 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier @ 2025-10-09  5:50 UTC (permalink / raw)
  To: Konrad Dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 2025-10-07 06:04, Konrad Dybcio wrote:
> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>> From: Alexandre Messier <alex@me.ssier.org>
>>
>> Add the touchscreen device node for the HTC One (M8).
>>
>> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
>> ---
>>  arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 36 +++++++++++++++++++++++
>>  1 file changed, 36 insertions(+)
>>
>> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>> index 36eb42f0f3d9..040a256f9465 100644
>> --- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>> +++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>> @@ -65,6 +65,35 @@ vreg_vph_pwr: vreg-vph-pwr {
>>  	};
>>  };
>>  
>> +&blsp1_i2c2 {
>> +	clock-frequency = <384000>;
> 
> This is not a valid I2C frequency
> 
> You're looking for 100/400/1000 kHz

Hello Konrad,

This frequency value is used in the vendor kernel [1], hence why I used it.

I did a test at 400 kHz, and the I2C devices (touchscreen here, and NFC in the
other patch) are still detected, with basic functions still working.

Let me know if I should still update to use 400 kHz. I would prefer to keep
the value from the vendor kernel (and in that case, I will update the commit
message to add that information).

Thanks

Alex

[1] https://github.com/LineageOS/android_kernel_htc_msm8974/blob/lineage-18.1/arch/arm/boot/dts/msm8974.dtsi#L970

> 
> Konrad
> 
> 


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

* Re: [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen
  2025-10-09  5:50     ` Alexandre Messier
@ 2025-10-09  9:30       ` Konrad Dybcio
  2025-10-12  6:06         ` Alexandre Messier
  0 siblings, 1 reply; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-09  9:30 UTC (permalink / raw)
  To: Alexandre Messier, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/9/25 7:50 AM, Alexandre Messier wrote:
> On 2025-10-07 06:04, Konrad Dybcio wrote:
>> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>>> From: Alexandre Messier <alex@me.ssier.org>
>>>
>>> Add the touchscreen device node for the HTC One (M8).
>>>
>>> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
>>> ---
>>>  arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 36 +++++++++++++++++++++++
>>>  1 file changed, 36 insertions(+)
>>>
>>> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>> index 36eb42f0f3d9..040a256f9465 100644
>>> --- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>> +++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>> @@ -65,6 +65,35 @@ vreg_vph_pwr: vreg-vph-pwr {
>>>  	};
>>>  };
>>>  
>>> +&blsp1_i2c2 {
>>> +	clock-frequency = <384000>;
>>
>> This is not a valid I2C frequency
>>
>> You're looking for 100/400/1000 kHz
> 
> Hello Konrad,
> 
> This frequency value is used in the vendor kernel [1], hence why I used it.
> 
> I did a test at 400 kHz, and the I2C devices (touchscreen here, and NFC in the
> other patch) are still detected, with basic functions still working.
> 
> Let me know if I should still update to use 400 kHz. I would prefer to keep
> the value from the vendor kernel (and in that case, I will update the commit
> message to add that information).

Hm, I grepped around in old vendor trees, and it seems like there was
a period of horrid wild west wrt this..

I see 355 kHz, 384 kHz, next to "normal" values of 100/400..

Let's just keep it as-is, but please note in the commit message that this
is intended and that's what the downstream sets too

Konrad

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

* Re: [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-07 10:03   ` Konrad Dybcio
@ 2025-10-12  6:03     ` Alexandre Messier
  2025-10-20 12:02       ` Konrad Dybcio
  0 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier @ 2025-10-12  6:03 UTC (permalink / raw)
  To: Konrad Dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 2025-10-07 06:03, Konrad Dybcio wrote:
> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>> From: Alexandre Messier <alex@me.ssier.org>
>>
>> Add support for the notification LEDs on the HTC One M8.
>>
>> Two LEDs are available, one amber and one green.
> 
> Do they form a single notification led, or are they supposed
> to act separately?

Good point, I had to check the phone user manual to confirm. Indeed, it is
referred to as a one logical notification LED. It also mentions the color can
be either green or orange, it does not mention using the combined color of
the two LEDs.

So I would say they are supposed to act separately.

Hope this answers your question, and let me know if more details are needed.

BTW: I will be sending a V2 to update the color name, since the user
manual says the color is orange, not amber.


> 
> Konrad
> 


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

* Re: [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen
  2025-10-09  9:30       ` Konrad Dybcio
@ 2025-10-12  6:06         ` Alexandre Messier
  0 siblings, 0 replies; 16+ messages in thread
From: Alexandre Messier @ 2025-10-12  6:06 UTC (permalink / raw)
  To: Konrad Dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 2025-10-09 05:30, Konrad Dybcio wrote:
> On 10/9/25 7:50 AM, Alexandre Messier wrote:
>> On 2025-10-07 06:04, Konrad Dybcio wrote:
>>> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>>>> From: Alexandre Messier <alex@me.ssier.org>
>>>>
>>>> Add the touchscreen device node for the HTC One (M8).
>>>>
>>>> Signed-off-by: Alexandre Messier <alex@me.ssier.org>
>>>> ---
>>>>  arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts | 36 +++++++++++++++++++++++
>>>>  1 file changed, 36 insertions(+)
>>>>
>>>> diff --git a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>>> index 36eb42f0f3d9..040a256f9465 100644
>>>> --- a/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>>> +++ b/arch/arm/boot/dts/qcom/qcom-msm8974pro-htc-m8.dts
>>>> @@ -65,6 +65,35 @@ vreg_vph_pwr: vreg-vph-pwr {
>>>>  	};
>>>>  };
>>>>  
>>>> +&blsp1_i2c2 {
>>>> +	clock-frequency = <384000>;
>>>
>>> This is not a valid I2C frequency
>>>
>>> You're looking for 100/400/1000 kHz
>>
>> Hello Konrad,
>>
>> This frequency value is used in the vendor kernel [1], hence why I used it.
>>
>> I did a test at 400 kHz, and the I2C devices (touchscreen here, and NFC in the
>> other patch) are still detected, with basic functions still working.
>>
>> Let me know if I should still update to use 400 kHz. I would prefer to keep
>> the value from the vendor kernel (and in that case, I will update the commit
>> message to add that information).
> 
> Hm, I grepped around in old vendor trees, and it seems like there was
> a period of horrid wild west wrt this..
> 
> I see 355 kHz, 384 kHz, next to "normal" values of 100/400..
> 
> Let's just keep it as-is, but please note in the commit message that this
> is intended and that's what the downstream sets too

Got it, for V2, I will add a note in the commit message, for this patch and the
other one (for the NFC support).

> 
> Konrad


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

* Re: [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-12  6:03     ` Alexandre Messier
@ 2025-10-20 12:02       ` Konrad Dybcio
  2025-10-22  7:00         ` Alexandre Messier
  0 siblings, 1 reply; 16+ messages in thread
From: Konrad Dybcio @ 2025-10-20 12:02 UTC (permalink / raw)
  To: Alexandre Messier, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Pavel Machek
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 10/12/25 8:03 AM, Alexandre Messier wrote:
> On 2025-10-07 06:03, Konrad Dybcio wrote:
>> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>>> From: Alexandre Messier <alex@me.ssier.org>
>>>
>>> Add support for the notification LEDs on the HTC One M8.
>>>
>>> Two LEDs are available, one amber and one green.
>>
>> Do they form a single notification led, or are they supposed
>> to act separately?
> 
> Good point, I had to check the phone user manual to confirm. Indeed, it is
> referred to as a one logical notification LED. It also mentions the color can
> be either green or orange, it does not mention using the combined color of
> the two LEDs.
> 
> So I would say they are supposed to act separately.
> 
> Hope this answers your question, and let me know if more details are needed.
> 
> BTW: I will be sending a V2 to update the color name, since the user
> manual says the color is orange, not amber.

Let's describe it as a single LED then:

multi-led {
        color = <LED_COLOR_ID_MULTI>; // notice it's not RGB
        function = LED_FUNCTION_STATUS;

        #address-cells = <1>;
        #size-cells = <0>;

        led@6 {
                reg = <6>;
                color = <LED_COLOR_ID_GREEN>;
        };

        led@7 {
                reg = <7>;
                color = <LED_COLOR_ID_ORANGE>;
        };
};

+ Pavel the LED maintainer, please take a look if you think it makes sense

Konrad

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

* Re: [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-20 12:02       ` Konrad Dybcio
@ 2025-10-22  7:00         ` Alexandre Messier
  2025-11-24 17:13           ` Pavel Machek
  0 siblings, 1 reply; 16+ messages in thread
From: Alexandre Messier @ 2025-10-22  7:00 UTC (permalink / raw)
  To: Konrad Dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Pavel Machek
  Cc: Luca Weiss, linux-arm-kernel, linux-arm-msm,
	~postmarketos/upstreaming, phone-devel, devicetree, linux-kernel

On 2025-10-20 08:02, Konrad Dybcio wrote:
> On 10/12/25 8:03 AM, Alexandre Messier wrote:
>> On 2025-10-07 06:03, Konrad Dybcio wrote:
>>> On 10/7/25 7:55 AM, Alexandre Messier via B4 Relay wrote:
>>>> From: Alexandre Messier <alex@me.ssier.org>
>>>>
>>>> Add support for the notification LEDs on the HTC One M8.
>>>>
>>>> Two LEDs are available, one amber and one green.
>>>
>>> Do they form a single notification led, or are they supposed
>>> to act separately?
>>
>> Good point, I had to check the phone user manual to confirm. Indeed, it is
>> referred to as a one logical notification LED. It also mentions the color can
>> be either green or orange, it does not mention using the combined color of
>> the two LEDs.
>>
>> So I would say they are supposed to act separately.
>>
>> Hope this answers your question, and let me know if more details are needed.
>>
>> BTW: I will be sending a V2 to update the color name, since the user
>> manual says the color is orange, not amber.
> 
> Let's describe it as a single LED then:
> 
> multi-led {
>         color = <LED_COLOR_ID_MULTI>; // notice it's not RGB
>         function = LED_FUNCTION_STATUS;
> 
>         #address-cells = <1>;
>         #size-cells = <0>;
> 
>         led@6 {
>                 reg = <6>;
>                 color = <LED_COLOR_ID_GREEN>;
>         };
> 
>         led@7 {
>                 reg = <7>;
>                 color = <LED_COLOR_ID_ORANGE>;
>         };
> };

Using multi-led is fine for me.

But currently, the "qcom-lpg" driver doesn't support LED_COLOR_ID_MULTI, only
LED_COLOR_ID_RGB. Adding support for LED_COLOR_ID_MULTI is trivial, I tested it
and it works.

Or I can also use the "leds-group-multicolor" driver, using the two individual
LEDs. I also tested this method and it works.

> 
> + Pavel the LED maintainer, please take a look if you think it makes sense

If Pavel agrees using multi-led makes sense, I think the first option is the
best. I will separate the LED patch into a new series, along with the change to
the qcom-lpg driver to support LED_COLOR_ID_MULTI.

Thanks
Alex

> 
> Konrad


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

* Re: [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs
  2025-10-22  7:00         ` Alexandre Messier
@ 2025-11-24 17:13           ` Pavel Machek
  0 siblings, 0 replies; 16+ messages in thread
From: Pavel Machek @ 2025-11-24 17:13 UTC (permalink / raw)
  To: Alexandre Messier
  Cc: Konrad Dybcio, Bjorn Andersson, Konrad Dybcio, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Luca Weiss, linux-arm-kernel,
	linux-arm-msm, ~postmarketos/upstreaming, phone-devel, devicetree,
	linux-kernel

[-- Attachment #1: Type: text/plain, Size: 2273 bytes --]

Hi!

> >>> Do they form a single notification led, or are they supposed
> >>> to act separately?
> >>
> >> Good point, I had to check the phone user manual to confirm. Indeed, it is
> >> referred to as a one logical notification LED. It also mentions the color can
> >> be either green or orange, it does not mention using the combined color of
> >> the two LEDs.
> >>
> >> So I would say they are supposed to act separately.
> >>
> >> Hope this answers your question, and let me know if more details are needed.
> >>
> >> BTW: I will be sending a V2 to update the color name, since the user
> >> manual says the color is orange, not amber.
> > 
> > Let's describe it as a single LED then:
> > 
> > multi-led {
> >         color = <LED_COLOR_ID_MULTI>; // notice it's not RGB
> >         function = LED_FUNCTION_STATUS;
> > 
> >         #address-cells = <1>;
> >         #size-cells = <0>;
> > 
> >         led@6 {
> >                 reg = <6>;
> >                 color = <LED_COLOR_ID_GREEN>;
> >         };
> > 
> >         led@7 {
> >                 reg = <7>;
> >                 color = <LED_COLOR_ID_ORANGE>;
> >         };
> > };
> 
> Using multi-led is fine for me.
> 
> But currently, the "qcom-lpg" driver doesn't support LED_COLOR_ID_MULTI, only
> LED_COLOR_ID_RGB. Adding support for LED_COLOR_ID_MULTI is trivial, I tested it
> and it works.
> 
> Or I can also use the "leds-group-multicolor" driver, using the two individual
> LEDs. I also tested this method and it works.
> 
> > 
> > + Pavel the LED maintainer, please take a look if you think it makes sense
> 
> If Pavel agrees using multi-led makes sense, I think the first option is the
> best. I will separate the LED patch into a new series, along with the change to
> the qcom-lpg driver to support LED_COLOR_ID_MULTI.

I see nothing horribly wrong here (and am late to the party). ID_MULTI
leds are pretty uncommon for phones, but if that's what you have...

Anyway:

LED SUBSYSTEM
M:      Lee Jones <lee@kernel.org>
M:      Pavel Machek <pavel@kernel.org>
L:      linux-leds@vger.kernel.org

Best regards,
								Pavel
-- 
I don't work for Nazis and criminals, and neither should you.
Boycott Putin, Trump, Netanyahu and Musk!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

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

end of thread, other threads:[~2025-11-24 17:13 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-07  5:55 [PATCH 0/4] Describe more hardware of the HTC One (M8) Alexandre Messier via B4 Relay
2025-10-07  5:55 ` [PATCH 1/4] ARM: dts: qcom: msm8974pro-htc-m8: add status LEDs Alexandre Messier via B4 Relay
2025-10-07 10:03   ` Konrad Dybcio
2025-10-12  6:03     ` Alexandre Messier
2025-10-20 12:02       ` Konrad Dybcio
2025-10-22  7:00         ` Alexandre Messier
2025-11-24 17:13           ` Pavel Machek
2025-10-07  5:55 ` [PATCH 2/4] ARM: dts: qcom: msm8974pro-htc-m8: add NFC support Alexandre Messier via B4 Relay
2025-10-07 10:03   ` Konrad Dybcio
2025-10-07  5:55 ` [PATCH 3/4] ARM: dts: qcom: msm8974pro-htc-m8: add Bluetooth pins Alexandre Messier via B4 Relay
2025-10-07 10:05   ` Konrad Dybcio
2025-10-07  5:55 ` [PATCH 4/4] ARM: dts: qcom: msm8974pro-htc-m8: add touchscreen Alexandre Messier via B4 Relay
2025-10-07 10:04   ` Konrad Dybcio
2025-10-09  5:50     ` Alexandre Messier
2025-10-09  9:30       ` Konrad Dybcio
2025-10-12  6:06         ` Alexandre Messier

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).