Opened 7 years ago

Last modified 4 years ago

#8258 new enhancement

[ACPI] laptop's brightness buttons need ACPI driver since hrev42637

Reported by: luroh Owned by: tqh
Priority: normal Milestone: R1
Component: Drivers/ACPI Version: R1/Development
Keywords: Cc: pulkomandy, degea@…
Blocked By: Blocking: #11214
Has a Patch: no Platform: All

Description

IBM/Lenovo T60, gcc2.

I fumbled and lost the revision at BG and had to go bisect again, sorry for the delay.

Change History (18)

comment:1 Changed 7 years ago by tqh

I lost it as well. Anyway thanks for the help.

comment:2 Changed 7 years ago by ttcoder

Cc: degea@… added

lenovo R61 here: 'Fn'-brightness does not work either... Glad to learn it's just a regression.. Jaw dropping seeing the "regression" revision is a big bad huge imported changeset -- this won't be trivially easy to track down I guess..

Last edited 7 years ago by ttcoder (previous) (diff)

comment:3 Changed 7 years ago by tqh

I have tested with hrev42633, and I think it has never worked with my laptop. I can try and look at the changes, but probably someone that can adjust brightness before this change needs to help out.

comment:4 Changed 7 years ago by korli

Just a theory... If the buttons work with ACPI disabled, the reason could be that by default the firmware handles brighness events itself. When ACPI is enabled, the firmware would not handle events anymore, thus leading to a "regression" for the user.

comment:5 Changed 7 years ago by tqh

It is possible, while I think it is not that likely. Latest ACPICA expects the OS to do more at init. So I think we just need to look at what ACPICA stopped doing. It may also be that the embedded controller stopped working properly in latest update.

comment:6 Changed 7 years ago by tqh

Also the first press worked for luroh at BG, so it is more likely an issue in handling or releasing the event properly.

comment:7 in reply to:  4 Changed 7 years ago by ttcoder

Replying to korli:

Just a theory... If the buttons work with ACPI disabled, the reason could be that by default the firmware handles brighness events itself. When ACPI is enabled, the firmware would not handle events anymore, thus leading to a "regression" for the user.

Just tried -- rebooted, disabled ACPI then proceeded with boot and... it works! Good hint/intuition, thanks. Could get me off the hook some day, so I don't need windows to setup the display on this laptop (an R61.. Not sure if this would be true also for this ticket's original poster, but here it works... though of course as a side-effet I lose the "battery indicator" in the deskbar).

comment:8 Changed 7 years ago by tqh

I also tested on two work latops, a Dell Inspiron D630 and a HP Elitebook. The Dell one always works and the HP don't work at all. So not so sure it is a problem with the code changes, perhaps we need to add a driver for brightness.

Still I don't have a good way to reproduce why it broke for you, so can't really do much to track that down.

comment:9 Changed 7 years ago by luroh

Indeed, disabling ACPI makes the brightness buttons (Fn + Home/End) work here. However, that also seems to be the only thing that works, as it makes booting hang with a stuck mouse pointer against an empty blue background.

comment:10 Changed 7 years ago by tqh

IIRC I commented on a similar bug, HP, Toshiba, Lenovo and some others needs special ACPI drivers. See FreeBSD drivers and what they do: http://fxr.watson.org/fxr/source/dev/acpi_support/

So basically everything works as expected, but nobody has written drivers for those laptops. Since I don't have any of them it is kind of hard for me to do.

comment:11 Changed 7 years ago by ttcoder

The ibm (lenovo) file does not seem terribly long or complex, though I suppose it's not reasonable for me to assume I can adapt it to haiku in a couple hours for my lenovo R61 ? I suppose there could be license problems (though it's probably liberal BSD/MIT), or more work than it seems to adapt it to the Haiku coding styleguide, or simply that the API changes are extensive or not easy to guess for a complete ACPI/hardware/kernel-land newbie ? Oh and let's not forget, I'm not setup for compiling the kernel and/or its add-ons and drivers :-P . Ok better forget it.

comment:12 Changed 5 years ago by tqh

Interesting comment in #7525 ... there are some vendors which produce laptops without support of generic ACPI methods, using instead proprietary ones. In such case you'll need to write platform-specific driver, like i did for Fujitsu-Siemens notebooks: ​https://github.com/druga/haiku-stuff/tree/master/acpi_fujitsu_laptop

comment:13 Changed 5 years ago by luroh

Summary: [ACPI] laptop's brightness buttons broken since hrev42637[ACPI] laptop's brightness buttons need ACPI driver since hrev42637

comment:14 Changed 5 years ago by luroh

Type: bugenhancement

comment:15 Changed 5 years ago by diver

Blocking: 11214 added

comment:16 Changed 4 years ago by pulkomandy

Can this be fixed now? It works again at least here (Thinkpad X200)

comment:17 Changed 4 years ago by tqh

No. It is still not functional. You are just lucky your laptop don't stop controlling it on ACPI init.

Note: See TracTickets for help on using tickets.