2023-04-18 16:45:08

by Luca Weiss

[permalink] [raw]
Subject: [PATCH v2 8/8] Documentation: leds: Add "rgb:status" path

The path /sys/class/leds/rgb:status is already widely used with the
qcom-lpg driver and others. Document it.

Signed-off-by: Luca Weiss <[email protected]>
---
Documentation/leds/well-known-leds.txt | 1 +
1 file changed, 1 insertion(+)

diff --git a/Documentation/leds/well-known-leds.txt b/Documentation/leds/well-known-leds.txt
index 2160382c86be..439d4dac4472 100644
--- a/Documentation/leds/well-known-leds.txt
+++ b/Documentation/leds/well-known-leds.txt
@@ -58,6 +58,7 @@ LEDs on notebook body, indicating that sound input / output is muted.

* System notification

+Good: "rgb:status"
Legacy: "status-led:{red,green,blue}" (Motorola Droid 4)
Legacy: "lp5523:{r,g,b}" (Nokia N900)


--
2.40.0


2023-04-27 16:10:46

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH v2 8/8] Documentation: leds: Add "rgb:status" path

On Tue, 18 Apr 2023, Luca Weiss wrote:

> The path /sys/class/leds/rgb:status is already widely used with the
> qcom-lpg driver and others. Document it.

Where is this used?

$ grep status drivers/leds/rgb/leds-qcom-lpg.c
<no results>

> Signed-off-by: Luca Weiss <[email protected]>
> ---
> Documentation/leds/well-known-leds.txt | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/Documentation/leds/well-known-leds.txt b/Documentation/leds/well-known-leds.txt
> index 2160382c86be..439d4dac4472 100644
> --- a/Documentation/leds/well-known-leds.txt
> +++ b/Documentation/leds/well-known-leds.txt
> @@ -58,6 +58,7 @@ LEDs on notebook body, indicating that sound input / output is muted.
>
> * System notification
>
> +Good: "rgb:status"
> Legacy: "status-led:{red,green,blue}" (Motorola Droid 4)
> Legacy: "lp5523:{r,g,b}" (Nokia N900)
>
>
> --
> 2.40.0
>

--
Lee Jones [李琼斯]

2023-04-27 17:56:16

by Luca Weiss

[permalink] [raw]
Subject: Re: [PATCH v2 8/8] Documentation: leds: Add "rgb:status" path

On Donnerstag, 27. April 2023 18:05:59 CEST Lee Jones wrote:
> On Tue, 18 Apr 2023, Luca Weiss wrote:
> > The path /sys/class/leds/rgb:status is already widely used with the
> > qcom-lpg driver and others. Document it.
>
> Where is this used?
>
> $ grep status drivers/leds/rgb/leds-qcom-lpg.c
> <no results>

This is set in devicetree, e.g. from qcom-msm8974pro-fairphone-fp2.dts[0]:

color = <LED_COLOR_ID_RGB>;
function = LED_FUNCTION_STATUS;

And then something in the LED core sets the name based on that, I'd have
to dig to find where exactly.

Regards
Luca

[0] https://github.com/torvalds/linux/blob/master/arch/arm/boot/dts/qcom-msm8974pro-fairphone-fp2.dts#L105-L106

>
> > Signed-off-by: Luca Weiss <[email protected]>
> > ---
> >
> > Documentation/leds/well-known-leds.txt | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/Documentation/leds/well-known-leds.txt
> > b/Documentation/leds/well-known-leds.txt index 2160382c86be..439d4dac4472
> > 100644
> > --- a/Documentation/leds/well-known-leds.txt
> > +++ b/Documentation/leds/well-known-leds.txt
> > @@ -58,6 +58,7 @@ LEDs on notebook body, indicating that sound input /
> > output is muted.>
> > * System notification
> >
> > +Good: "rgb:status"
> >
> > Legacy: "status-led:{red,green,blue}" (Motorola Droid 4)
> > Legacy: "lp5523:{r,g,b}" (Nokia N900)