From: Jacek Anaszewski <jacek.anaszewski@gmail.com>
To: Dan Murphy <dmurphy@ti.com>, pavel@ucw.cz
Cc: linux-leds@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v12 04/16] leds: multicolor: Introduce a multicolor class definition
Date: Fri, 11 Oct 2019 21:53:20 +0200 [thread overview]
Message-ID: <651f42b4-a15c-d9ae-9a83-0a0567d61230@gmail.com> (raw)
In-Reply-To: <20191011130657.4713-5-dmurphy@ti.com>
Dan,
On 10/11/19 3:06 PM, Dan Murphy wrote:
> Introduce a multicolor class that groups colored LEDs
> within a LED node.
>
> The multi color class groups monochrome LEDs and allows controlling two
> aspects of the final combined color: hue and lightness. The former is
> controlled via <color>_intensity files and the latter is controlled
> via brightness file.
>
> Signed-off-by: Dan Murphy <dmurphy@ti.com>
> ---
> .../ABI/testing/sysfs-class-led-multicolor | 36 +++
> .../bindings/leds/leds-class-multicolor.txt | 4 +-
> Documentation/leds/index.rst | 1 +
> Documentation/leds/leds-class-multicolor.rst | 96 +++++++
> drivers/leds/Kconfig | 10 +
> drivers/leds/Makefile | 1 +
> drivers/leds/led-class-multicolor.c | 271 ++++++++++++++++++
> include/linux/led-class-multicolor.h | 143 +++++++++
> 8 files changed, 560 insertions(+), 2 deletions(-)
> create mode 100644 Documentation/ABI/testing/sysfs-class-led-multicolor
> create mode 100644 Documentation/leds/leds-class-multicolor.rst
> create mode 100644 drivers/leds/led-class-multicolor.c
> create mode 100644 include/linux/led-class-multicolor.h
>
> diff --git a/Documentation/ABI/testing/sysfs-class-led-multicolor b/Documentation/ABI/testing/sysfs-class-led-multicolor
> new file mode 100644
> index 000000000000..3d1f9d726c70
> --- /dev/null
> +++ b/Documentation/ABI/testing/sysfs-class-led-multicolor
> @@ -0,0 +1,36 @@
> +What: /sys/class/leds/<led>/brightness
> +Date: Sept 2019
> +KernelVersion: 5.5
> +Contact: Dan Murphy <dmurphy@ti.com>
> +Description: read/write
> + Writing to this file will update all LEDs within the group to a
> + calculated percentage of what each color LED intensity is set
> + to. The percentage is calculated for each grouped LED via the
> + equation below:
> +
> + led_brightness = brightness * <color>_intensity/<color>_max_intensity
> +
> + For additional details please refer to
> + Documentation/leds/leds-class-multicolor.rst.
> +
> + The value of the color is from 0 to
> + /sys/class/leds/<led>/max_brightness.
> +
> +What: /sys/class/leds/<led>/colors/<color>_intensity
> +Date: Sept 2019
> +KernelVersion: 5.5
> +Contact: Dan Murphy <dmurphy@ti.com>
> +Description: read/write
> + The <color>_intensity file is created based on the color
> + defined by the registrar of the class.
> + There is one file per color presented.
> +
> + The value of the color is from 0 to
> + /sys/class/leds/<led>/colors/<color>_max_intensity.
> +
> +What: /sys/class/leds/<led>/colors/<color>_max_intensity
> +Date: Sept 2019
> +KernelVersion: 5.5
> +Contact: Dan Murphy <dmurphy@ti.com>
> +Description: read only
> + Maximum intensity level for the LED color.
> diff --git a/Documentation/devicetree/bindings/leds/leds-class-multicolor.txt b/Documentation/devicetree/bindings/leds/leds-class-multicolor.txt
> index 8619c9bf1811..4b1bd82f2a42 100644
> --- a/Documentation/devicetree/bindings/leds/leds-class-multicolor.txt
> +++ b/Documentation/devicetree/bindings/leds/leds-class-multicolor.txt
> @@ -10,7 +10,7 @@ The nodes and properties defined in this document are unique to the multicolor
> LED class. Common LED nodes and properties are inherited from the common.txt
> within this documentation directory.
>
> -Required LED Child properties:
> +Required LED child properties:
> - color : For multicolor LED support this property should be defined as
> LED_COLOR_ID_MULTI and further definition can be found in
> include/linux/leds/common.h.
> @@ -26,7 +26,7 @@ led-controller@30 {
> #size-cells = <0>;
> reg = <1>;
> color = <LED_COLOR_ID_MULTI>;
> - function = LED_FUNCTION_STATUS;
> + function = LED_FUNCTION_CHARGING;
>
So this went to wrong patch.
--
Best regards,
Jacek Anaszewski
next prev parent reply other threads:[~2019-10-11 19:53 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-11 13:06 [PATCH v12 00/16] Multicolor Framework v12 Dan Murphy
2019-10-11 13:06 ` [PATCH v12 01/16] dt: bindings: Add multicolor class dt bindings documention Dan Murphy
2019-10-11 13:06 ` [PATCH v12 02/16] dt-bindings: leds: Add multicolor ID to the color ID list Dan Murphy
2019-10-11 13:06 ` [PATCH v12 03/16] " Dan Murphy
2019-10-11 13:06 ` [PATCH v12 04/16] leds: multicolor: Introduce a multicolor class definition Dan Murphy
2019-10-11 19:53 ` Jacek Anaszewski [this message]
2019-10-14 6:18 ` kbuild test robot
2019-10-11 13:06 ` [PATCH v12 05/16] dt: bindings: lp50xx: Introduce the lp50xx family of RGB drivers Dan Murphy
2019-10-11 13:06 ` [PATCH v12 06/16] leds: lp50xx: Add the LP50XX family of the RGB LED driver Dan Murphy
2019-10-11 20:04 ` Jacek Anaszewski
2019-10-14 9:17 ` kbuild test robot
2019-10-19 17:13 ` Jacek Anaszewski
2019-10-21 11:46 ` Dan Murphy
2019-10-11 13:06 ` [PATCH v12 07/16] dt: bindings: lp55xx: Be consistent in the document with LED acronym Dan Murphy
2019-10-11 13:06 ` [PATCH v12 08/16] dt: bindings: lp55xx: Update binding for Multicolor Framework Dan Murphy
2019-10-11 20:15 ` Jacek Anaszewski
2019-10-12 0:54 ` Dan Murphy
2019-10-12 13:32 ` Jacek Anaszewski
2019-10-11 13:06 ` [PATCH v12 09/16] ARM: dts: n900: Add reg property to the LP5523 channel node Dan Murphy
2019-10-11 13:06 ` [PATCH v12 10/16] ARM: dts: imx6dl-yapp4: Add reg property to the lp5562 " Dan Murphy
2019-10-11 13:06 ` [PATCH v12 11/16] ARM: dts: ste-href: Add reg property to the LP5521 channel nodes Dan Murphy
2019-10-11 13:06 ` [PATCH v12 12/16] leds: lp55xx: Add multicolor framework support to lp55xx Dan Murphy
2019-10-11 20:36 ` Jacek Anaszewski
2019-10-12 0:50 ` Dan Murphy
2019-10-12 13:27 ` Jacek Anaszewski
2019-10-11 13:06 ` [PATCH v12 13/16] leds: lp5523: Update the lp5523 code to add intensity function Dan Murphy
2019-10-11 13:06 ` [PATCH v12 14/16] leds: lp5521: Add multicolor framework intensity support Dan Murphy
2019-10-11 13:06 ` [PATCH v12 15/16] leds: lp55xx: Fix checkpatch file permissions issues Dan Murphy
2019-10-11 13:06 ` [PATCH v12 16/16] leds: lp5523: Fix checkpatch issues in the code Dan Murphy
2019-10-11 19:40 ` [PATCH v12 00/16] Multicolor Framework v12 Jacek Anaszewski
2019-10-12 0:48 ` Dan Murphy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=651f42b4-a15c-d9ae-9a83-0a0567d61230@gmail.com \
--to=jacek.anaszewski@gmail.com \
--cc=dmurphy@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-leds@vger.kernel.org \
--cc=pavel@ucw.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).