<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/video/backlight/backlight.c, branch linux-4.20.y</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=linux-4.20.y</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=linux-4.20.y'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2018-01-29T15:34:53+00:00</updated>
<entry>
<title>video: backlight: Add devres versions of of_find_backlight</title>
<updated>2018-01-29T15:34:53+00:00</updated>
<author>
<name>Meghana Madhyastha</name>
<email>meghana.madhyastha@gmail.com</email>
</author>
<published>2018-01-24T16:37:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2e4ef3347b4a4eb65c4fd950d94bbd75fed4d798'/>
<id>urn:sha1:2e4ef3347b4a4eb65c4fd950d94bbd75fed4d798</id>
<content type='text'>
Add devm_of_find_backlight and the corresponding release
function because some drivers use devres versions of functions
for acquiring device resources.

Acked-by: Daniel Thompson &lt;daniel.thompson@linaro.org&gt;
Reviewed-by: Noralf Trønnes &lt;noralf@tronnes.org&gt;
Reviewed-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Signed-off-by: Meghana Madhyastha &lt;meghana.madhyastha@gmail.com&gt;
Signed-off-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/021f8fecfa3f374dc5dcb70fb07a6f6b019bea7b.1516810725.git.meghana.madhyastha@gmail.com
</content>
</entry>
<entry>
<title>video: backlight: Add of_find_backlight helper in backlight.c</title>
<updated>2018-01-29T15:34:53+00:00</updated>
<author>
<name>Meghana Madhyastha</name>
<email>meghana.madhyastha@gmail.com</email>
</author>
<published>2018-01-24T16:35:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=c2adda27d202fa8f70a5d6e8b0c12b449c8868b8'/>
<id>urn:sha1:c2adda27d202fa8f70a5d6e8b0c12b449c8868b8</id>
<content type='text'>
Add of_find_backlight, a helper function which is a generic version
of tinydrm_of_find_backlight that can be used by other drivers to avoid
repetition of code and simplify things.

Acked-by: Daniel Thompson &lt;daniel.thompson@linaro.org&gt;
Reviewed-by: Noralf Trønnes &lt;noralf@tronnes.org&gt;
Reviewed-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Reviewed-by: Thierry Reding &lt;treding@nvidia.com&gt;
Signed-off-by: Meghana Madhyastha &lt;meghana.madhyastha@gmail.com&gt;
Signed-off-by: Sean Paul &lt;seanpaul@chromium.org&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/116d160ba78be2e6dcbdcb6855622bce67da9472.1516810725.git.meghana.madhyastha@gmail.com
</content>
</entry>
<entry>
<title>backlight: Report error on failure</title>
<updated>2017-05-30T08:27:53+00:00</updated>
<author>
<name>Sudip Mukherjee</name>
<email>sudipm.mukherjee@gmail.com</email>
</author>
<published>2017-05-17T20:55:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7e715c2d9c27c23f3187454157c58cf292ed103e'/>
<id>urn:sha1:7e715c2d9c27c23f3187454157c58cf292ed103e</id>
<content type='text'>
It is possible to update the backlight power and the brightness using
the sysfs and on writing it either returns the count or if the callback
function does not exist then returns the error code 'ENXIO'.

We have a situation where the userspace client is writing to the sysfs
to update the power and since the callback function exists the client
receives the return value as count and considers the operation to be
successful. That is correct as the write to the sysfs was successful.
But there is no way to know if the actual operation was done or not.

backlight_update_status() returns the error code if it fails. Pass that
to the userspace client who is trying to update the power so that the
client knows that the operation failed.

Signed-off-by: Sudip Mukherjee &lt;sudip.mukherjee@codethink.co.uk&gt;
Acked-by: Daniel Thompson &lt;daniel.thompson@linaro.org&gt;
Signed-off-by: Lee Jones &lt;lee.jones@linaro.org&gt;
</content>
</entry>
<entry>
<title>video / backlight: remove the backlight_device_registered API</title>
<updated>2016-05-04T21:41:14+00:00</updated>
<author>
<name>Aaron Lu</name>
<email>aaron.lu@intel.com</email>
</author>
<published>2016-04-27T12:45:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=01c3664de62f89f6777e59173ad8e20b5a4c267f'/>
<id>urn:sha1:01c3664de62f89f6777e59173ad8e20b5a4c267f</id>
<content type='text'>
Since we will need the backlight_device_get_by_type API, we can use it
instead of the backlight_device_registered API whenever necessary so
remove the backlight_device_registered API.

Signed-off-by: Aaron Lu &lt;aaron.lu@intel.com&gt;
Acked-by: Jingoo Han &lt;jg1.han@samsung.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>video / backlight: add two APIs for drivers to use</title>
<updated>2016-05-04T21:41:14+00:00</updated>
<author>
<name>Aaron Lu</name>
<email>aaron.lu@intel.com</email>
</author>
<published>2016-04-27T12:45:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=f6a4790a5471d7cba406d87f6b41323f40bb93d2'/>
<id>urn:sha1:f6a4790a5471d7cba406d87f6b41323f40bb93d2</id>
<content type='text'>
It is useful to get the backlight device's pointer and use it to set
backlight in some cases(the following patch will make use of it) so add
the two APIs and export them.

Signed-off-by: Aaron Lu &lt;aaron.lu@intel.com&gt;
Acked-by: Jingoo Han &lt;jg1.han@samsung.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>backlight: Show brightness even if get_brightness is not implemented</title>
<updated>2014-06-23T12:26:02+00:00</updated>
<author>
<name>Andrzej Hajda</name>
<email>a.hajda@samsung.com</email>
</author>
<published>2014-05-30T10:10:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=b3de3402e5ab8edfbbdbbb86393692431522f6d3'/>
<id>urn:sha1:b3de3402e5ab8edfbbdbbb86393692431522f6d3</id>
<content type='text'>
Many implementations of get_brightness operation returns only value
of props.brightness field. This change makes such implementations
unnecessary.

Acked-by: Jingoo Han &lt;jg1.han@samsung.com&gt;
Signed-off-by: Andrzej Hajda &lt;a.hajda@samsung.com&gt;
Signed-off-by: Lee Jones &lt;lee.jones@linaro.org&gt;
</content>
</entry>
<entry>
<title>backlight: Add backlight device (un)registration notification</title>
<updated>2014-05-26T23:29:01+00:00</updated>
<author>
<name>Hans de Goede</name>
<email>hdegoede@redhat.com</email>
</author>
<published>2014-05-21T13:39:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3cc6919bd61315ea60baf95f3f9868aacfd1ace4'/>
<id>urn:sha1:3cc6919bd61315ea60baf95f3f9868aacfd1ace4</id>
<content type='text'>
Some firmware drivers, ie acpi-video want to get themselves out of the
way (in some cases) when their also is a raw backlight device available.

Due to module loading ordering being unknown, acpi-video cannot be certain
that the backlight_device_registered(BACKLIGHT_RAW) it does for this is
the final verdict wrt there being a BACKLIGHT_RAW device.

By adding notification acpi-video can listen for backlight devices showing
up after it has loaded, and unregister its backlight device if desired.

Signed-off-by: Hans de Goede &lt;hdegoede@redhat.com&gt;
Acked-by: Jingoo Han &lt;jg1.han@samsung.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge tag 'backlight-for-linus-3.15' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight</title>
<updated>2014-04-10T15:52:35+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2014-04-10T15:52:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=edf2377c4776ce20ae990f27f0248e88a37e25c4'/>
<id>urn:sha1:edf2377c4776ce20ae990f27f0248e88a37e25c4</id>
<content type='text'>
Pull backlight changes from Lee Jones:
 - core: call put_device() instead of kfree()
 - gpio-backlight: add DT support
 - lm3639_bl driver: use managed resources

* tag 'backlight-for-linus-3.15' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight:
  backlight: lm3639: Use devm_backlight_device_register()
  backlight: gpio-backlight: Add DT support
  backlight: core: Replace kfree with put_device
</content>
</entry>
<entry>
<title>backlight: core: Replace kfree with put_device</title>
<updated>2014-04-08T12:20:39+00:00</updated>
<author>
<name>Levente Kurusa</name>
<email>levex@linux.com</email>
</author>
<published>2014-02-07T08:43:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=35762a47c0a24072a689cbd98ecf8c62b037ef8a'/>
<id>urn:sha1:35762a47c0a24072a689cbd98ecf8c62b037ef8a</id>
<content type='text'>
As per the comments on device_register, we shouldn't call kfree()
right after a device_register() failure. Instead call put_device(),
which in turn will call bl_device_release resulting in a kfree to the
full structure.

Signed-off-by: Levente Kurusa &lt;levex@linux.com&gt;
Acked-by: Jingoo Han &lt;jg1.han@samsung.com&gt;
Signed-off-by: Lee Jones &lt;lee.jones@linaro.org&gt;
</content>
</entry>
<entry>
<title>backlight: update backlight status when necessary</title>
<updated>2014-04-03T23:21:09+00:00</updated>
<author>
<name>Liu Ying</name>
<email>Ying.Liu@freescale.com</email>
</author>
<published>2014-04-03T21:48:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=8c16f3303c3410d4af19c8bdc73b74c83c042e87'/>
<id>urn:sha1:8c16f3303c3410d4af19c8bdc73b74c83c042e87</id>
<content type='text'>
We don't have to update a backlight status every time a blanking or
unblanking event comes because the backlight status may have already
been what we want.  Another thought is that one backlight device may be
shared by multiple framebuffers.  We don't hope blanking one of the
framebuffers may turn the backlight off for all the other framebuffers,
since they are likely being active to display something.

This patch makes the backlight status be updated only when the relevant
backlight device's use count changes from zero to one or from one to
zero.

Signed-off-by: Liu Ying &lt;Ying.Liu@freescale.com&gt;
Cc: Jingoo Han &lt;jg1.han@samsung.com&gt;
Cc: Jean-Christophe PLAGNIOL-VILLARD &lt;plagnioj@jcrosoft.com&gt;
Cc: Tomi Valkeinen &lt;tomi.valkeinen@ti.com&gt;
Cc: Jani Nikula &lt;jani.nikula@linux.intel.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
