You are not logged in.

#1 2012-04-25 14:07:44

axs
Member
Registered: 2009-01-23
Posts: 71
Website

Backlight hotkeys unexpected behavior

Got a weird problem with backlight hotkeys: every keypress makes the backlight return to something close to its default brightness. It looks like the keys have some kind of default (and buggy) handler, which I can't disable. Any ideas what can it be, or where to look?

To clarify: it's the behavior of unhandled brightness-up and brightness-down keys. I can add a handler via acpid that writes a value to intel_backlight/brightness, it works, but the default action still remains somewhere, which makes the screen flash at lower settings. I.e., keypress -> default backlight -> handler writes a value -> low backlight, with the whole sequence taking maybe .1s or so.

It's a Dell v131 laptop with an Intel card (HD3000, I presume), and with up to date Arch installation; kernel 3.3.2-1-ARCH.

Backlight is controlled via /sys/class/backlight/intel_backlight/brightness; just writing values there works without any flashes.

acpi_backlight=vendor doesn't seem to affect anything, and neither do i915_enable_rc6 or pcie_aspm=force.

X doesn't seem to affect anything; acpid works and the flashes happen even with no X server running.

The hotkeys, Fn+F5 and Fn+F6, are visible to acpid as video/brightnessup and video/brightnessdown.

This default action is same for both keys, and it seems to be exactly "set fixed value", not "brightness up/down".

I don't think I have anything else that could control backlight, at least ps ax shows nothing usual, but please correct me if I'm wrong here.

The keys work correctly in grub (and before that), switching between 15 acpi levels.

The keys stop working as soon as the kernel starts loading, but this annoying set-default-brightnesss behavior only appears about the time udev events are triggered. Sadly it all happens too fast to note the exact time, and I don't think I can boot Arch with udev disabled anyway.

Last edited by axs (2012-04-25 14:09:48)

Offline

#2 2012-09-29 15:04:20

norkward
Member
Registered: 2012-09-29
Posts: 3

Re: Backlight hotkeys unexpected behavior

I have a similar problem on my Thinkpad Edge E330.

The hotkeys for increasing and decreasing are working, but on the one hand the maximum brightness is not reached and on the other hand,  if I go down at some point the brightness is increased again.

Setting the brightness with echo 2000 > /sys/class/backlight/intel_backlight/brightness works.

Where could this hotkeys be registered?
I would like to fix this or remove the hotkey and and set it with acpid in my /etc/acpi/handler.sh.

Offline

#3 2012-09-29 15:56:22

teateawhy
Member
From: GER
Registered: 2012-03-05
Posts: 1,138
Website

Re: Backlight hotkeys unexpected behavior

norkward wrote:

Where could this hotkeys be registered?

xmodmap -pke | grep Bright
keycode 232 = XF86MonBrightnessDown NoSymbol XF86MonBrightnessDown
keycode 233 = XF86MonBrightnessUp NoSymbol XF86MonBrightnessUp
keycode 237 = XF86KbdBrightnessDown NoSymbol XF86KbdBrightnessDown
keycode 238 = XF86KbdBrightnessUp NoSymbol XF86KbdBrightnessUp

You can also use xmodmap to rename the keys, acpi should stop acting upon key press then.

Offline

#4 2012-09-29 15:57:48

David Batson
Member
Registered: 2011-10-13
Posts: 640

Re: Backlight hotkeys unexpected behavior

Offhand I think it might be related to the /usr/lib/pm-utils/video-quirks files.

There are files in there for different brands of hardware.

Could be wrong though.

You could also run "xev" in terminal and "acpi_listen" in terminal to see how those hotkeys are seen by the system.  Oftentimes these hotkey combos send a XF86* code or else an acpi code.  It is possible to change or use the XF86* code (depending), or use the acpi code, or else use different hotkeys (or key combos) to run a script file such as /etc/acpi/handler.sh, or your own script file.

Offline

#5 2012-09-29 16:06:52

WonderWoofy
Member
From: Los Gatos, CA
Registered: 2012-05-19
Posts: 8,414

Re: Backlight hotkeys unexpected behavior

norkward wrote:

I have a similar problem on my Thinkpad Edge E330.

norkward, your machine should be using the thinkpad_acpi module along with the nvram module.  Do these modules show up with lsmod?

Offline

#6 2012-09-30 10:34:51

norkward
Member
Registered: 2012-09-29
Posts: 3

Re: Backlight hotkeys unexpected behavior

Problem is nearly solved now.
Neither X nor thinkpad_acpi was responsible for the hotkeys, because they worked also in console and after removing thinkpad_acpi it still worked.
I think the default acpi kernel driver was the problem. After adding acpi_backlight=vendor to the kernel parameters the problems are gone, but the minimum brightness is about 200 and not 0. I think the intel graphic driver is handling the hotkeys.

Does someone know where I can configure it?

Offline

#7 2012-09-30 12:15:03

David Batson
Member
Registered: 2011-10-13
Posts: 640

Re: Backlight hotkeys unexpected behavior

Based upon your above post, you may find the following helpful.

https://wiki.edubuntu.org/Kernel/Debugging/Backlight

Offline

#8 2012-10-02 20:18:35

Haikarainen
Member
Registered: 2012-09-04
Posts: 93

Re: Backlight hotkeys unexpected behavior

Offline

Board footer

Powered by FluxBB