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

Luca Weiss posted 8 patches 2 years, 8 months ago
There is a newer version of this series
[PATCH v2 8/8] Documentation: leds: Add "rgb:status" path
Posted by Luca Weiss 2 years, 8 months ago
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 <luca@z3ntu.xyz>
---
 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
Re: [PATCH v2 8/8] Documentation: leds: Add "rgb:status" path
Posted by Lee Jones 2 years, 7 months ago
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 <luca@z3ntu.xyz>
> ---
>  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 [李琼斯]
Re: [PATCH v2 8/8] Documentation: leds: Add "rgb:status" path
Posted by Luca Weiss 2 years, 7 months ago
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 <luca@z3ntu.xyz>
> > ---
> > 
> >  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)