All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
@ 2022-05-05 16:43 Luca Weiss
  2022-05-06 15:10 ` kernel test robot
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Luca Weiss @ 2022-05-05 16:43 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: ~postmarketos/upstreaming, phone-devel, André Almeida,
	Luca Weiss, Andy Gross, Bjorn Andersson, Rob Herring,
	Krzysztof Kozlowski, devicetree, linux-kernel

From: André Almeida <andrealmeid@collabora.com>

Nexus 5 has a RGB LED connected to the TRILED and hence channels 7, 6 and
5 of the LPG. Add a node describing this.

Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
Signed-off-by: André Almeida <andrealmeid@collabora.com>
---
This patch depends on the PM8941 LPG patch:
https://lore.kernel.org/linux-arm-msm/20220504205411.1510667-1-bjorn.andersson@linaro.org/

 .../qcom-msm8974-lge-nexus5-hammerhead.dts    | 30 +++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dts b/arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dts
index 9493886a5c0d..94f3149d9f87 100644
--- a/arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dts
+++ b/arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dts
@@ -3,6 +3,7 @@
 #include "qcom-pm8841.dtsi"
 #include "qcom-pm8941.dtsi"
 #include <dt-bindings/input/input.h>
+#include <dt-bindings/leds/common.h>
 #include <dt-bindings/pinctrl/qcom,pmic-gpio.h>
 
 / {
@@ -313,6 +314,35 @@ otg {
 	};
 };
 
+&pm8941_lpg {
+	status = "okay";
+
+	qcom,power-source = <1>;
+
+	multi-led {
+		color = <LED_COLOR_ID_RGB>;
+		function = LED_FUNCTION_STATUS;
+
+		#address-cells = <1>;
+		#size-cells = <0>;
+
+		led@7 {
+			reg = <7>;
+			color = <LED_COLOR_ID_RED>;
+		};
+
+		led@6 {
+			reg = <6>;
+			color = <LED_COLOR_ID_GREEN>;
+		};
+
+		led@5 {
+			reg = <5>;
+			color = <LED_COLOR_ID_BLUE>;
+		};
+	};
+};
+
 &rpm_requests {
 	pm8841-regulators {
 		compatible = "qcom,rpm-pm8841-regulators";
-- 
2.36.0


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

* Re: [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
  2022-05-05 16:43 [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED Luca Weiss
@ 2022-05-06 15:10 ` kernel test robot
  2022-05-30  7:06 ` Pavel Machek
  2022-07-17  3:08 ` (subset) " Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: kernel test robot @ 2022-05-06 15:10 UTC (permalink / raw)
  To: Luca Weiss, linux-arm-msm
  Cc: kbuild-all, ~postmarketos/upstreaming, phone-devel,
	André Almeida, Luca Weiss, Andy Gross, Bjorn Andersson,
	Rob Herring, Krzysztof Kozlowski, devicetree, linux-kernel

Hi Luca,

I love your patch! Yet something to improve:

[auto build test ERROR on next-20220505]
[cannot apply to robh/for-next v5.18-rc5 v5.18-rc4 v5.18-rc3 v5.18-rc5]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/intel-lab-lkp/linux/commits/Luca-Weiss/ARM-dts-qcom-msm8974-hammerhead-Add-notification-LED/20220506-004626
base:    632a8c88e339fe86ae6e420a24dfc641d4dd0ab5
config: arm-allmodconfig (https://download.01.org/0day-ci/archive/20220506/202205062319.gc3Q6aGA-lkp@intel.com/config)
compiler: arm-linux-gnueabi-gcc (GCC) 11.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/intel-lab-lkp/linux/commit/982ec92f3741358d8ce62dd43841b550a6ab6a22
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Luca-Weiss/ARM-dts-qcom-msm8974-hammerhead-Add-notification-LED/20220506-004626
        git checkout 982ec92f3741358d8ce62dd43841b550a6ab6a22
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

>> Error: arch/arm/boot/dts/qcom-msm8974-lge-nexus5-hammerhead.dts:317.1-12 Label or path pm8941_lpg not found
>> FATAL ERROR: Syntax error parsing input tree

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

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

* Re: [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
  2022-05-05 16:43 [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED Luca Weiss
  2022-05-06 15:10 ` kernel test robot
@ 2022-05-30  7:06 ` Pavel Machek
  2022-05-30 20:57   ` Luca Weiss
  2022-07-17  3:08 ` (subset) " Bjorn Andersson
  2 siblings, 1 reply; 5+ messages in thread
From: Pavel Machek @ 2022-05-30  7:06 UTC (permalink / raw)
  To: Luca Weiss
  Cc: linux-arm-msm, ~postmarketos/upstreaming, phone-devel,
	Andr?? Almeida, Andy Gross, Bjorn Andersson, Rob Herring,
	Krzysztof Kozlowski, devicetree, linux-kernel

Hi!

> From: Andr?? Almeida <andrealmeid@collabora.com>
> 
> Nexus 5 has a RGB LED connected to the TRILED and hence channels 7, 6 and
> 5 of the LPG. Add a node describing this.
> 
> Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
> Signed-off-by: Andr?? Almeida <andrealmeid@collabora.com>

> --- This patch depends on the PM8941 LPG patch: 
> https://lore.kernel.org/linux-arm-msm/20220504205411.1510667-1-bjorn.andersson@linaro.org/

How does this LED end up looking in userland? We want to make sure all the phone RGB status LEDs 
end up using same path in /sys/..

Best regards,

									Pavel

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

* Re: [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
  2022-05-30  7:06 ` Pavel Machek
@ 2022-05-30 20:57   ` Luca Weiss
  0 siblings, 0 replies; 5+ messages in thread
From: Luca Weiss @ 2022-05-30 20:57 UTC (permalink / raw)
  To: Pavel Machek
  Cc: linux-arm-msm, ~postmarketos/upstreaming, phone-devel,
	Andr?? Almeida, Andy Gross, Bjorn Andersson, Rob Herring,
	Krzysztof Kozlowski, devicetree, linux-kernel

Hi Pavel,

On Montag, 30. Mai 2022 09:06:19 CEST Pavel Machek wrote:
> Hi!
> 
> > From: Andr?? Almeida <andrealmeid@collabora.com>
> > 
> > Nexus 5 has a RGB LED connected to the TRILED and hence channels 7, 6 and
> > 5 of the LPG. Add a node describing this.
> > 
> > Signed-off-by: Luca Weiss <luca@z3ntu.xyz>
> > Signed-off-by: Andr?? Almeida <andrealmeid@collabora.com>
> > 
> > --- This patch depends on the PM8941 LPG patch:
> > https://lore.kernel.org/linux-arm-msm/20220504205411.1510667-1-bjorn.ander
> > sson@linaro.org/
> How does this LED end up looking in userland? We want to make sure all the
> phone RGB status LEDs end up using same path in /sys/..

Like this, on both hammerhead and FP2 (in a separate patch):

$ ls -al /sys/class/leds/rgb:status/
total 0
drwxr-xr-x 3 root root         0 Jan  5  1970 .
drwxr-xr-x 3 root root         0 Jan  5  1970 ..
-rw-rw-r-- 1 root feedbackd 4096 Jan  5  1970 brightness
lrwxrwxrwx 1 root root         0 May 30 13:59 device -> ../../../fc4cf000.spmi:pm8941@1:lpg
-r--r--r-- 1 root root      4096 Jan  5  1970 max_brightness
-r--r--r-- 1 root root      4096 Jan  5  1970 multi_index
-rw-rw-r-- 1 root feedbackd 4096 Jan  5  1970 multi_intensity
drwxr-xr-x 2 root root         0 May 30 13:59 power
lrwxrwxrwx 1 root root         0 Jan  5  1970 subsystem -> ../../../../../../../../../class/leds
-rw-r--r-- 1 root root         0 Jan  5  1970 trigger
-rw-r--r-- 1 root root      4096 Jan  5  1970 uevent

Regards
Luca

> 
> Best regards,
> 
> 									Pavel





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

* Re: (subset) [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
  2022-05-05 16:43 [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED Luca Weiss
  2022-05-06 15:10 ` kernel test robot
  2022-05-30  7:06 ` Pavel Machek
@ 2022-07-17  3:08 ` Bjorn Andersson
  2 siblings, 0 replies; 5+ messages in thread
From: Bjorn Andersson @ 2022-07-17  3:08 UTC (permalink / raw)
  To: linux-arm-msm, Luca Weiss
  Cc: Krzysztof Kozlowski, ~postmarketos/upstreaming, Andy Gross,
	linux-kernel, Rob Herring, André Almeida, phone-devel,
	devicetree

On Thu, 5 May 2022 18:43:37 +0200, Luca Weiss wrote:
> From: André Almeida <andrealmeid@collabora.com>
> 
> Nexus 5 has a RGB LED connected to the TRILED and hence channels 7, 6 and
> 5 of the LPG. Add a node describing this.
> 
> 

Applied, thanks!

[1/1] ARM: dts: qcom: msm8974-hammerhead: Add notification LED
      commit: 1ea9098a81133d54b3d40d7ffd197f77881e5ecc

Best regards,
-- 
Bjorn Andersson <bjorn.andersson@linaro.org>

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

end of thread, other threads:[~2022-07-17  3:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-05 16:43 [PATCH] ARM: dts: qcom: msm8974-hammerhead: Add notification LED Luca Weiss
2022-05-06 15:10 ` kernel test robot
2022-05-30  7:06 ` Pavel Machek
2022-05-30 20:57   ` Luca Weiss
2022-07-17  3:08 ` (subset) " Bjorn Andersson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.