I'm putting back the CC and adding Alex.
On Tue, Jul 31, 2012 at 5:07 PM, Pali Rohár pali.rohar@gmail.com wrote:
Thanks, now working. When I write to acpi video brightness file it change brightness and in dmesg is:
[ 47.200998] [drm:radeon_atif_handler], event, device_class = video, type = 0xd0 [ 47.201102] [drm:radeon_atif_get_sbios_requests], SBIOS pending requests: 0x80 [ 47.201104] [drm:radeon_atif_handler], ATIF: 1 pending SBIOS requests [ 47.201105] [drm:radeon_atif_handler], Changing brightness to 11
Great! I'll send an updated patch to Alex soon.
I think that acpi only sent event about brightness key pressed, because nothing happened when I pressed it.
Also for windows is needed special HP application (hp hotkey) for brightness keys. Without it brightness keys not working too...
I've looked at hp-wmi: the hotkey is indeed dispatched via WMI (hp-wmi) so you need something in userspace (KDE, Gnome, etc) to respond to that key press.
And there is one problem with /sys/class/backlight/radeon_bl. When I enable Ambient Light Sensor which auto adjust brightness based on sensor data, writing value 0 (min) or 255 (max) to /sys/class/backlight/radeon_bl/brightness turn off display.
Ok, that's weird. 0 turns off the panel by design, 255 should not...
All other values (1-254) are OK (adjust brightness level). When I turn off Ambient Light Sensor (via hp-wmi kernel module) then values 0 and 255 also set brightness level (min and max). My suggestion is to convert value 0 to 1 and 255 to 254 to prevent this problem.
No idea what's going on here... might be some weird vendor magic. The WMI code is rather obscure...
Luca
On Tue, Jul 31, 2012 at 11:49 AM, Luca Tettamanti kronos.it@gmail.com wrote:
I'm putting back the CC and adding Alex.
On Tue, Jul 31, 2012 at 5:07 PM, Pali Rohár pali.rohar@gmail.com wrote:
Thanks, now working. When I write to acpi video brightness file it change brightness and in dmesg is:
[ 47.200998] [drm:radeon_atif_handler], event, device_class = video, type = 0xd0 [ 47.201102] [drm:radeon_atif_get_sbios_requests], SBIOS pending requests: 0x80 [ 47.201104] [drm:radeon_atif_handler], ATIF: 1 pending SBIOS requests [ 47.201105] [drm:radeon_atif_handler], Changing brightness to 11
Great! I'll send an updated patch to Alex soon.
I think that acpi only sent event about brightness key pressed, because nothing happened when I pressed it.
Also for windows is needed special HP application (hp hotkey) for brightness keys. Without it brightness keys not working too...
I've looked at hp-wmi: the hotkey is indeed dispatched via WMI (hp-wmi) so you need something in userspace (KDE, Gnome, etc) to respond to that key press.
And there is one problem with /sys/class/backlight/radeon_bl. When I enable Ambient Light Sensor which auto adjust brightness based on sensor data, writing value 0 (min) or 255 (max) to /sys/class/backlight/radeon_bl/brightness turn off display.
Ok, that's weird. 0 turns off the panel by design, 255 should not...
All other values (1-254) are OK (adjust brightness level). When I turn off Ambient Light Sensor (via hp-wmi kernel module) then values 0 and 255 also set brightness level (min and max). My suggestion is to convert value 0 to 1 and 255 to 254 to prevent this problem.
No idea what's going on here... might be some weird vendor magic. The WMI code is rather obscure...
FWIW, there is also a bit in the atom firmware info table (WMI_SUPPORT) to tell whether the system uses WMI or not. We can probably use that to limit the max backlight if 255 causes problems for other WMI systems. I'm not sure how the interaction with WMI is supposed to work however.
Alex
On Tuesday 31 July 2012 17:49:32 Luca Tettamanti wrote:
I'm putting back the CC and adding Alex.
On Tue, Jul 31, 2012 at 5:07 PM, Pali Rohár
pali.rohar@gmail.com wrote:
Thanks, now working. When I write to acpi video brightness file it change brightness and in dmesg is:
[ 47.200998] [drm:radeon_atif_handler], event, device_class = video, type = 0xd0 [ 47.201102] [drm:radeon_atif_get_sbios_requests], SBIOS pending requests: 0x80 [ 47.201104] [drm:radeon_atif_handler], ATIF: 1 pending SBIOS requests [ 47.201105] [drm:radeon_atif_handler], Changing brightness to 11
Great! I'll send an updated patch to Alex soon.
I think that acpi only sent event about brightness key pressed, because nothing happened when I pressed it.
Also for windows is needed special HP application (hp hotkey) for brightness keys. Without it brightness keys not working too...
I've looked at hp-wmi: the hotkey is indeed dispatched via WMI (hp-wmi) so you need something in userspace (KDE, Gnome, etc) to respond to that key press.
No, when I rmmod hp-wmi brightness keys still generate events. And when I disable acpi then brightness keys do not generate events but adjust brightness automatically (by BIOS).
I think that hp-wmi on my notebook only handle bluetooth & wifi rfkills and ALS switch. All button working without hp-wmi too.
And there is one problem with /sys/class/backlight/radeon_bl. When I enable Ambient Light Sensor which auto adjust brightness based on sensor data, writing value 0 (min) or 255 (max) to /sys/class/backlight/radeon_bl/brightness turn off display.
Ok, that's weird. 0 turns off the panel by design, 255 should not...
But when ALS is disabled 0 did not turn display off.
All other values (1-254) are OK (adjust brightness level). When I turn off Ambient Light Sensor (via hp-wmi kernel module) then values 0 and 255 also set brightness level (min and max). My suggestion is to convert value 0 to 1 and 255 to 254 to prevent this problem.
No idea what's going on here... might be some weird vendor magic. The WMI code is rather obscure...
Luca
ACPI/WMI cannot change brightness, see this what doing that ALS function: http://lists.freedesktop.org/archives/dri-devel/2012- March/020416.html
On Tue, Jul 31, 2012 at 12:03 PM, Pali Rohár pali.rohar@gmail.com wrote:
On Tuesday 31 July 2012 17:49:32 Luca Tettamanti wrote:
I'm putting back the CC and adding Alex.
On Tue, Jul 31, 2012 at 5:07 PM, Pali Rohár
pali.rohar@gmail.com wrote:
Thanks, now working. When I write to acpi video brightness file it change brightness and in dmesg is:
[ 47.200998] [drm:radeon_atif_handler], event, device_class = video, type = 0xd0 [ 47.201102] [drm:radeon_atif_get_sbios_requests], SBIOS pending requests: 0x80 [ 47.201104] [drm:radeon_atif_handler], ATIF: 1 pending SBIOS requests [ 47.201105] [drm:radeon_atif_handler], Changing brightness to 11
Great! I'll send an updated patch to Alex soon.
I think that acpi only sent event about brightness key pressed, because nothing happened when I pressed it.
Also for windows is needed special HP application (hp hotkey) for brightness keys. Without it brightness keys not working too...
I've looked at hp-wmi: the hotkey is indeed dispatched via WMI (hp-wmi) so you need something in userspace (KDE, Gnome, etc) to respond to that key press.
No, when I rmmod hp-wmi brightness keys still generate events. And when I disable acpi then brightness keys do not generate events but adjust brightness automatically (by BIOS).
I think that hp-wmi on my notebook only handle bluetooth & wifi rfkills and ALS switch. All button working without hp-wmi too.
And there is one problem with /sys/class/backlight/radeon_bl. When I enable Ambient Light Sensor which auto adjust brightness based on sensor data, writing value 0 (min) or 255 (max) to /sys/class/backlight/radeon_bl/brightness turn off display.
Ok, that's weird. 0 turns off the panel by design, 255 should not...
But when ALS is disabled 0 did not turn display off.
0 only turns off the backlight, not the panel itself. Is the backlight still partially on or is it just the actual panel (timing and image)?
Alex
On Tuesday 31 July 2012 12:17:05 Alex Deucher wrote:
On Tue, Jul 31, 2012 at 12:03 PM, Pali Rohár
pali.rohar@gmail.com wrote:
On Tuesday 31 July 2012 17:49:32 Luca Tettamanti wrote:
I'm putting back the CC and adding Alex.
On Tue, Jul 31, 2012 at 5:07 PM, Pali Rohár
pali.rohar@gmail.com wrote:
Thanks, now working. When I write to acpi video brightness file it change brightness and in dmesg is:
[ 47.200998] [drm:radeon_atif_handler], event, device_class = video, type = 0xd0 [ 47.201102] [drm:radeon_atif_get_sbios_requests], SBIOS pending requests: 0x80 [ 47.201104] [drm:radeon_atif_handler], ATIF: 1 pending SBIOS requests [ 47.201105] [drm:radeon_atif_handler], Changing brightness to 11
Great! I'll send an updated patch to Alex soon.
I think that acpi only sent event about brightness key pressed, because nothing happened when I pressed it.
Also for windows is needed special HP application (hp hotkey) for brightness keys. Without it brightness keys not working too...
I've looked at hp-wmi: the hotkey is indeed dispatched via WMI (hp-wmi) so you need something in userspace (KDE, Gnome, etc) to respond to that key press.
No, when I rmmod hp-wmi brightness keys still generate events. And when I disable acpi then brightness keys do not generate events but adjust brightness automatically (by BIOS).
I think that hp-wmi on my notebook only handle bluetooth & wifi rfkills and ALS switch. All button working without hp-wmi too.>
And there is one problem with /sys/class/backlight/radeon_bl. When I enable Ambient Light Sensor which auto adjust brightness based on sensor data, writing value 0 (min) or 255 (max) to /sys/class/backlight/radeon_bl/brightness turn off display.
Ok, that's weird. 0 turns off the panel by design, 255 should not...
But when ALS is disabled 0 did not turn display off.
0 only turns off the backlight, not the panel itself. Is the backlight still partially on or is it just the actual panel (timing and image)?
Alex
I looked at display again and 0 only turn backlight off (or adjust minimum value). If I look at display correctly (in dark room) I can recognize that display is still on and I can see window manager decorations (but text is not readable).
Value 255 when ALS is on has same effect as 0 - adjust minimum value (instead maximum).
dri-devel@lists.freedesktop.org