<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/leds, branch v2.6.33.5</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>leds-gpio: fix default state handling on OF platforms</title>
<updated>2010-04-01T23:01:58+00:00</updated>
<author>
<name>Anton Vorontsov</name>
<email>avorontsov@ru.mvista.com</email>
</author>
<published>2010-03-11T21:58:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5eeb7b28921a88b6f8de786f34178345626b051e'/>
<id>5eeb7b28921a88b6f8de786f34178345626b051e</id>
<content type='text'>
commit 0493a4ff10959ff4c8e0d65efee25b7ffd4fa5db upstream.

The driver wrongly sets default state for LEDs that don't specify
default-state property.

Currently the driver handles default state this way:

memset(&amp;led, 0, sizeof(led));
for_each_child_of_node(np, child) {
	state = of_get_property(child, "default-state", NULL);
	if (state) {
		if (!strcmp(state, "keep"))
			led.default_state = LEDS_GPIO_DEFSTATE_KEEP;
		...
	}
	ret = create_gpio_led(&amp;led, ...);
}

Which means that all LEDs that do not specify default-state will inherit
the last value of the default-state property, which is wrong.

This patch fixes the issue by moving LED's template initialization into
the loop body.

Signed-off-by: Anton Vorontsov &lt;avorontsov@ru.mvista.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 0493a4ff10959ff4c8e0d65efee25b7ffd4fa5db upstream.

The driver wrongly sets default state for LEDs that don't specify
default-state property.

Currently the driver handles default state this way:

memset(&amp;led, 0, sizeof(led));
for_each_child_of_node(np, child) {
	state = of_get_property(child, "default-state", NULL);
	if (state) {
		if (!strcmp(state, "keep"))
			led.default_state = LEDS_GPIO_DEFSTATE_KEEP;
		...
	}
	ret = create_gpio_led(&amp;led, ...);
}

Which means that all LEDs that do not specify default-state will inherit
the last value of the default-state property, which is wrong.

This patch fixes the issue by moving LED's template initialization into
the loop body.

Signed-off-by: Anton Vorontsov &lt;avorontsov@ru.mvista.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>leds: leds-pwm: Set led_classdev max_brightness</title>
<updated>2009-12-17T11:42:34+00:00</updated>
<author>
<name>Lars-Peter Clausen</name>
<email>lars@metafoo.de</email>
</author>
<published>2009-11-27T05:17:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e45906203d27296b47e56efc1219f9a200bfc2db'/>
<id>e45906203d27296b47e56efc1219f9a200bfc2db</id>
<content type='text'>
Currently the driver leds-pwm doesn't set max_brightness for the led device
although it's platform data proides a maximum brightness. Instead it stores its
own private driver struct. The max_brightness defaults to 255 for led device if
it has not been set.
As a result any leds-pwm device with a different maximum brightness will show
incorrect behavior, as it is posible to either set a longer then period duty
time or not be able to switch the led to full brightness.

Signed-off-by: Lars-Peter Clausen &lt;lars@metafoo.de&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently the driver leds-pwm doesn't set max_brightness for the led device
although it's platform data proides a maximum brightness. Instead it stores its
own private driver struct. The max_brightness defaults to 255 for led device if
it has not been set.
As a result any leds-pwm device with a different maximum brightness will show
incorrect behavior, as it is posible to either set a longer then period duty
time or not be able to switch the led to full brightness.

Signed-off-by: Lars-Peter Clausen &lt;lars@metafoo.de&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: use default-on trigger for Cobalt Qube</title>
<updated>2009-12-17T11:38:31+00:00</updated>
<author>
<name>Florian Fainelli</name>
<email>florian@openwrt.org</email>
</author>
<published>2009-11-26T18:41:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=51de036ba388a1bda08755f7c0d3d1ae27c81e66'/>
<id>51de036ba388a1bda08755f7c0d3d1ae27c81e66</id>
<content type='text'>
This patch changes the default trigger from "ide-disk"
to "default-on". Users updating from kernels not having this
LED driver will prefer having the same LED behavior as they
used to.

Signed-off-by: Florian Fainelli &lt;florian@openwrt.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch changes the default trigger from "ide-disk"
to "default-on". Users updating from kernels not having this
LED driver will prefer having the same LED behavior as they
used to.

Signed-off-by: Florian Fainelli &lt;florian@openwrt.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: drivers/leds/leds-ss4200.c: fix return statement</title>
<updated>2009-12-17T11:36:40+00:00</updated>
<author>
<name>akpm@linux-foundation.org</name>
<email>akpm@linux-foundation.org</email>
</author>
<published>2009-11-14T03:56:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=eedd898f6910b88aa2052461ad0c3f443b45bb00'/>
<id>eedd898f6910b88aa2052461ad0c3f443b45bb00</id>
<content type='text'>
drivers/leds/leds-ss4200.c: In function 'ich7_lpc_probe':
drivers/leds/leds-ss4200.c:353: warning: 'return' with no value, in function returning non-void

Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
drivers/leds/leds-ss4200.c: In function 'ich7_lpc_probe':
drivers/leds/leds-ss4200.c:353: warning: 'return' with no value, in function returning non-void

Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: Add LED class driver for regulator driven LEDs.</title>
<updated>2009-12-17T11:27:09+00:00</updated>
<author>
<name>Antonio Ospite</name>
<email>ospite@studenti.unina.it</email>
</author>
<published>2009-12-07T14:08:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d4cc6a2eee98faebf2c7d3ebc4b35541c1d47d21'/>
<id>d4cc6a2eee98faebf2c7d3ebc4b35541c1d47d21</id>
<content type='text'>
This driver provides an interface for controlling LEDs (or vibrators)
connected to PMICs for which there is a regulator framework driver.

This driver can be used, for instance, to control vibrator on all Motorola EZX
phones using the pcap-regulator driver services.

Signed-off-by: Antonio Ospite &lt;ospite@studenti.unina.it&gt;
Reviewed-by: Mark Brown &lt;broonie@opensource.wolfsonmicro.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This driver provides an interface for controlling LEDs (or vibrators)
connected to PMICs for which there is a regulator framework driver.

This driver can be used, for instance, to control vibrator on all Motorola EZX
phones using the pcap-regulator driver services.

Signed-off-by: Antonio Ospite &lt;ospite@studenti.unina.it&gt;
Reviewed-by: Mark Brown &lt;broonie@opensource.wolfsonmicro.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: leds-cobalt-qube.c: use resource_size()</title>
<updated>2009-12-17T11:18:15+00:00</updated>
<author>
<name>H Hartley Sweeten</name>
<email>hartleys@visionengravers.com</email>
</author>
<published>2009-12-11T21:50:58+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3c0f6e1eddeddd95ed04d4a7f0e55ab0aa99adf9'/>
<id>3c0f6e1eddeddd95ed04d4a7f0e55ab0aa99adf9</id>
<content type='text'>
Use resource_size() for ioremap.

Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use resource_size() for ioremap.

Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: leds-cobalt-raq.c - use resource_size()</title>
<updated>2009-12-17T11:16:23+00:00</updated>
<author>
<name>H Hartley Sweeten</name>
<email>hartleys@visionengravers.com</email>
</author>
<published>2009-12-11T23:13:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d3aad6399a240300534d83ffdacfc40e6ed4fa73'/>
<id>d3aad6399a240300534d83ffdacfc40e6ed4fa73</id>
<content type='text'>
Use resource_size() for ioremap.

Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use resource_size() for ioremap.

Signed-off-by: H Hartley Sweeten &lt;hsweeten@visionengravers.com&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: Add driver for ADP5520/ADP5501 MFD PMICs</title>
<updated>2009-12-16T11:30:10+00:00</updated>
<author>
<name>Michael Hennerich</name>
<email>michael.hennerich@analog.com</email>
</author>
<published>2009-10-08T08:00:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=ed4a10b47ff1e4059157f33248a62d9551ced786'/>
<id>ed4a10b47ff1e4059157f33248a62d9551ced786</id>
<content type='text'>
Signed-off-by: Michael Hennerich &lt;michael.hennerich@analog.com&gt;
Signed-off-by: Bryan Wu &lt;cooloney@kernel.org&gt;
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Michael Hennerich &lt;michael.hennerich@analog.com&gt;
Signed-off-by: Bryan Wu &lt;cooloney@kernel.org&gt;
Signed-off-by: Mike Frysinger &lt;vapier@gentoo.org&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds: Add driver for LT3593 controlled LEDs</title>
<updated>2009-12-16T11:30:09+00:00</updated>
<author>
<name>Daniel Mack</name>
<email>daniel@caiaq.de</email>
</author>
<published>2009-10-15T00:59:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=a8dd18feb68ef0c5d3ec02f7d198740ddd7e8fd3'/>
<id>a8dd18feb68ef0c5d3ec02f7d198740ddd7e8fd3</id>
<content type='text'>
The LT3593 is a step-up DC/DC converter designed to drive up to ten
white LEDs in series. The current flow can be set with a control pin.

This driver controls any number of such devices connected on generic
GPIOs and exports the function as as platform_driver.

The gpio_led platform data struct definition is reused for this purpose.

Successfully tested on a PXA embedded board.

Signed-off-by: Daniel Mack &lt;daniel@caiaq.de&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The LT3593 is a step-up DC/DC converter designed to drive up to ten
white LEDs in series. The current flow can be set with a control pin.

This driver controls any number of such devices connected on generic
GPIOs and exports the function as as platform_driver.

The gpio_led platform data struct definition is reused for this purpose.

Successfully tested on a PXA embedded board.

Signed-off-by: Daniel Mack &lt;daniel@caiaq.de&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>leds-ss4200: Check pci_enable_device return</title>
<updated>2009-12-16T11:30:09+00:00</updated>
<author>
<name>Dave Hansen</name>
<email>dave@sr71.net</email>
</author>
<published>2009-10-14T16:20:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=09a46db05b2e07484c08c638d7d6bda0523a13a6'/>
<id>09a46db05b2e07484c08c638d7d6bda0523a13a6</id>
<content type='text'>
pci_enable_result is defined using the __must_check macro but
leds-ss4200 is not checking the return value.

Signed-off-by: Javier Martinez Canillas &lt;martinez.javier@gmail.com&gt;
Signed-off-by: Dave Hansen &lt;dave@sr71.net&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
pci_enable_result is defined using the __must_check macro but
leds-ss4200 is not checking the return value.

Signed-off-by: Javier Martinez Canillas &lt;martinez.javier@gmail.com&gt;
Signed-off-by: Dave Hansen &lt;dave@sr71.net&gt;
Signed-off-by: Richard Purdie &lt;rpurdie@linux.intel.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
