<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/include/linux/leds.h, branch v5.10.207</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v5.10.207</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v5.10.207'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2020-07-22T12:42:07Z</updated>
<entry>
<title>leds: trigger: add support for LED-private device triggers</title>
<updated>2020-07-22T12:42:07Z</updated>
<author>
<name>Marek Behún</name>
<email>marek.behun@nic.cz</email>
</author>
<published>2020-07-16T17:17:28Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=93690cdf3060c61dfce813121d0bfc055e7fa30d'/>
<id>urn:sha1:93690cdf3060c61dfce813121d0bfc055e7fa30d</id>
<content type='text'>
Some LED controllers may come with an internal HW triggering mechanism
for the LED and the ability to switch between SW control and the
internal HW control. This includes most PHYs, various ethernet switches,
the Turris Omnia LED controller or AXP20X PMIC.

This adds support for registering such triggers.

This code is based on work by Pavel Machek &lt;pavel@ucw.cz&gt; and
Ondřej Jirman &lt;megous@megous.com&gt;.

Signed-off-by: Marek Behún &lt;marek.behun@nic.cz&gt;
Acked-by: Jacek Anaszewski &lt;jacek.anaszewski@gmail.com&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: old enums are not really applicable to new code</title>
<updated>2020-04-06T20:55:27Z</updated>
<author>
<name>Pavel Machek</name>
<email>pavel@ucw.cz</email>
</author>
<published>2020-03-21T16:01:53Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=c7e4ea68c1626cceb966323a4b572e2f8d805138'/>
<id>urn:sha1:c7e4ea68c1626cceb966323a4b572e2f8d805138</id>
<content type='text'>
Warn about old defines that probably should not be used.

Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: Add managed API to get a LED from a device driver</title>
<updated>2020-01-05T23:20:18Z</updated>
<author>
<name>Jean-Jacques Hiblot</name>
<email>jjhiblot@ti.com</email>
</author>
<published>2019-10-03T08:28:10Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e389240ad99292d52a4f8ff30f16830dc9c63779'/>
<id>urn:sha1:e389240ad99292d52a4f8ff30f16830dc9c63779</id>
<content type='text'>
If the LED is acquired by a consumer device with devm_led_get(), it is
automatically released when the device is detached.

Signed-off-by: Jean-Jacques Hiblot &lt;jjhiblot@ti.com&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: Add of_led_get() and led_put()</title>
<updated>2020-01-05T23:20:06Z</updated>
<author>
<name>Tomi Valkeinen</name>
<email>tomi.valkeinen@ti.com</email>
</author>
<published>2019-10-03T08:28:09Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=699a8c7c4bd376aee4808e6272188319e900c8af'/>
<id>urn:sha1:699a8c7c4bd376aee4808e6272188319e900c8af</id>
<content type='text'>
This patch adds basic support for a kernel driver to get a LED device.
This will be used by the led-backlight driver.

Only OF version is implemented for now, and the behavior is similar to
PWM's of_pwm_get() and pwm_put().

Signed-off-by: Tomi Valkeinen &lt;tomi.valkeinen@ti.com&gt;
Signed-off-by: Jean-Jacques Hiblot &lt;jjhiblot@ti.com&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: core: Fix leds.h structure documentation</title>
<updated>2019-11-03T16:38:55Z</updated>
<author>
<name>Dan Murphy</name>
<email>dmurphy@ti.com</email>
</author>
<published>2019-10-02T12:40:42Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=9cc93be7b0c91a87ef452457c706af62741249d7'/>
<id>urn:sha1:9cc93be7b0c91a87ef452457c706af62741249d7</id>
<content type='text'>
Update the leds.h structure documentation to define the
correct arguments.

Signed-off-by: Dan Murphy &lt;dmurphy@ti.com&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: core: Remove extern from header</title>
<updated>2019-11-03T16:38:46Z</updated>
<author>
<name>Dan Murphy</name>
<email>dmurphy@ti.com</email>
</author>
<published>2019-10-02T12:40:40Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ec28a8cfdce6306afcbf528e231a733010c82251'/>
<id>urn:sha1:ec28a8cfdce6306afcbf528e231a733010c82251</id>
<content type='text'>
extern is implied and is not needed in the header file.
Remove the extern keyword and re-align the code.

Signed-off-by: Dan Murphy &lt;dmurphy@ti.com&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: remove PAGE_SIZE limit of /sys/class/leds/&lt;led&gt;/trigger</title>
<updated>2019-11-03T16:38:14Z</updated>
<author>
<name>Akinobu Mita</name>
<email>akinobu.mita@gmail.com</email>
</author>
<published>2019-09-29T14:18:49Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=11f70002213774ed233950f71ea8803fa3700aa3'/>
<id>urn:sha1:11f70002213774ed233950f71ea8803fa3700aa3</id>
<content type='text'>
Reading /sys/class/leds/&lt;led&gt;/trigger returns all available LED triggers.
However, the size of this file is limited to PAGE_SIZE because of the
limitation for sysfs attribute.

Enabling LED CPU trigger on systems with thousands of CPUs easily hits
PAGE_SIZE limit, and makes it impossible to see all available LED triggers
and which trigger is currently activated.

We work around it here by converting /sys/class/leds/&lt;led&gt;/trigger to
binary attribute, which is not limited by length. This is _not_ good
design, do not copy it.

Signed-off-by: Akinobu Mita &lt;akinobu.mita@gmail.com&gt;
Cc: "Rafael J. Wysocki" &lt;rafael@kernel.org&gt;
Cc: Pavel Machek &lt;pavel@ucw.cz&gt;
Cc: Dan Murphy &lt;dmurphy@ti.com&gt;A
Reviewed-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: Replace {devm_}led_classdev_register() macros with inlines</title>
<updated>2019-09-01T11:33:16Z</updated>
<author>
<name>Jacek Anaszewski</name>
<email>jacek.anaszewski@gmail.com</email>
</author>
<published>2019-08-26T20:34:42Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=7c322056e3564da1b5bdc3f3cb79229582955eb2'/>
<id>urn:sha1:7c322056e3564da1b5bdc3f3cb79229582955eb2</id>
<content type='text'>
Replace preprocessor macro aliases for legacy LED registration helpers
with inline functions. It will allow to avoid misleading compiler error
messages about missing symbol that actually wasn't explicitly used
in the code. It used to occur when CONFIG_LEDS_CLASS was undefined
and legacy (non-ext) function had been used in the code.

Signed-off-by: Jacek Anaszewski &lt;jacek.anaszewski@gmail.com&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: core: Add support for composing LED class device names</title>
<updated>2019-07-25T18:07:52Z</updated>
<author>
<name>Jacek Anaszewski</name>
<email>jacek.anaszewski@gmail.com</email>
</author>
<published>2019-06-09T18:19:04Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=bb4e9af0348dfeafd66c7e7f82e8a0983fe5390c'/>
<id>urn:sha1:bb4e9af0348dfeafd66c7e7f82e8a0983fe5390c</id>
<content type='text'>
Add generic support for composing LED class device name. The newly
introduced led_compose_name() function composes device name according
to either &lt;color:function&gt; or &lt;devicename:color:function&gt; pattern,
depending on the configuration of initialization data.

Backward compatibility with in-driver hard-coded LED class device
names is assured thanks to the default_label and devicename properties
of newly introduced struct led_init_data.

In case none of the aforementioned properties was found, then, for OF
nodes, the node name is adopted for LED class device name.

At the occassion of amending the Documentation/leds/leds-class.txt
unify spelling: colour -&gt; color.

Alongside these changes added is a new tool - tools/leds/get_led_device_info.sh.
The tool allows retrieving details of a LED class device's parent device,
which proves that using vendor or product name for devicename part
of LED name doesn't convey any added value since that information had been
already available in sysfs. The script performs also basic validation
of a LED class device name.

Signed-off-by: Jacek Anaszewski &lt;jacek.anaszewski@gmail.com&gt;
Cc: Baolin Wang &lt;baolin.wang@linaro.org&gt;
Cc: Dan Murphy &lt;dmurphy@ti.com&gt;
Cc: Daniel Mack &lt;daniel@zonque.org&gt;
Cc: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Oleh Kravchenko &lt;oleg@kaa.org.ua&gt;
Cc: Sakari Ailus &lt;sakari.ailus@linux.intel.com&gt;
Cc: Simon Shields &lt;simon@lineageos.org&gt;
Reviewed-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
<entry>
<title>leds: class: Improve LED and LED flash class registration API</title>
<updated>2019-07-25T18:07:50Z</updated>
<author>
<name>Jacek Anaszewski</name>
<email>jacek.anaszewski@gmail.com</email>
</author>
<published>2019-06-09T18:19:03Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=b2b998c0f944993c9ef435569651e407d607af41'/>
<id>urn:sha1:b2b998c0f944993c9ef435569651e407d607af41</id>
<content type='text'>
Replace of_led_classdev_register() with led_classdev_register_ext(), which
accepts easily extendable struct led_init_data, instead of the fixed
struct device_node argument. The latter can be now passed in an fwnode
property of the struct led_init_data.

The modification is driven by the need for passing additional arguments
required for the forthcoming generic mechanism for composing LED names.
Currently the LED name is conveyed in the "name" char pointer property of
the struct led_classdev. This is redundant since LED class device name
is accessible throughout the whole LED class device life time via
associated struct device's kobj-&gt;name property.

The change will not break any existing clients since the patch alters
also existing led_classdev{_flash}_register() macro wrappers, that pass
NULL in place of init_data, which leads to using legacy name
initialization path basing on the struct led_classdev's "name" property.

Three existing users of devm_of_led_classdev_registers() are modified
to use devm_led_classdev_register(), which will not impact their
operation since they in fact didn't need to pass struct device_node on
registration from the beginning.

Signed-off-by: Jacek Anaszewski &lt;jacek.anaszewski@gmail.com&gt;
Cc: Baolin Wang &lt;baolin.wang@linaro.org&gt;
Cc: Dan Murphy &lt;dmurphy@ti.com&gt;
Cc: Daniel Mack &lt;daniel@zonque.org&gt;
Cc: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Cc: Oleh Kravchenko &lt;oleg@kaa.org.ua&gt;
Cc: Sakari Ailus &lt;sakari.ailus@linux.intel.com&gt;
Cc: Simon Shields &lt;simon@lineageos.org&gt;
Acked-by: Pavel Machek &lt;pavel@ucw.cz&gt;
</content>
</entry>
</feed>
