-
-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Backlight turns off completely when brightness reaches zero #179
Comments
I notice this too, but is this not expected behaviour? It's nice to be able to fully adjust the backlight |
Well, it cannot be expected that the backlight turns off completely, making the screen completely unreadable. I cannot imagine a use case for that. On the other hand, I checked an older laptop (Lenovo T60) which has 8 brightness levels and level It is quite unfortunate that the kernel is inconsistent in what 'zero brightness' means. The only API I could find is not clear about it. https://www.kernel.org/doc/Documentation/ABI/stable/sysfs-class-backlight |
I have a Lenovo E540 and I have the same behavior as your L540. Do you have this message in the logs on boot up by any chance? thinkpad_acpi unsupported brightness interface This is definitely a kernel problem, I will look into it and fix it. Was looking for a reason to make another kernel contribution to be honest! We probably use the same drivers for both our Lenovo machines (hopefully). Would you test on your machine if I gave you a guide, once I make the fix? |
As your L450 I meant! |
I looked up the issue once (I have the message too), and this message does not indicate a kernel bug. |
See the bug report and the patch. I would happily test on my machine if there is a patch. Maybe we could send a message to Richard Purdie (apparently the maintainer of |
They actually got rid of this error log and changed it to info instead which is more correct: |
Emailed a couple of guys on the kernel mailing list: |
Thank you for working on this issue! :) |
It looks like my email may have been ignored though! Which is strange, normally the kernel community is quite responsive. |
Wait actually one of my email filters caught it by mistake. Looks like the minimum brightness issue will be staying at least in the short term: "Whether '0' means 'off' or 'lowest brightness level' has been Anyway, both features (turning backlight off and lowest backlight |
Well, if they don't want to change the kernel interface, I think the best solution would be to put another 'file' in that directory called something like In the meantime, we could make a list of devices that are known to be completely off at brightness 0. IMHO, that's still something we shouldn't need to care about, but until the kernel provides us this information it's a workable solution. I'm prepared to write a patch if needed. Right now I'm installing the Debian sources. |
A patch fixing this issue on the MATE side rather than the kernel side? Yeah, that would be cool, let me know if you want any help. I feel like we are just working around a kernel issue here but if it works, that's fine I guess! :) |
I'm not so sure I want to sign up for the LKML (AFAIK it has a lot of traffic), but maybe you can propose such an interface? In the mean time I've looked into the issue. I think I can fix it, but I cannot promise anything. |
Well, it turns out this stuff isn't so simple... I was under the impression that mate-power-manager managed the brightness directly. Apparently this isn't the case (which is logical as a normal user cannot directly change brightness). It looks like it is managed within X11 via the I ran mate-power-manager with
So, X11 reports the wrong values. |
Here is a hack/workaround if you're interested. This works on my laptop. That is, I haven't actually tested the git source, but doing the same modifications to the Debian package works for me. The first commit was necessary, it appears this is a bug in the handling of Feel free to merge one or both of the commits. Note: the Oh, and I found this thread: http://thread.gmane.org/gmane.comp.freedesktop.xorg.drivers.intel/19680/focus=19680 |
I probably won't merge, this doesn't annoy me enough to compile my own package :) But if you plan on merging this to master of course I can build and test this. I suppose you could just check what symlink/directory is in /sys/class/backlight and do this if it's interl_backlight or is that a bit hacky, is there a cleaner way of checking? This will work I guess. Do all distros use this directory structure? /sys/class/backlight I'm just asking the question I don't actually know. |
kernel problem. on 3.2.11 this worked fine (min brightness=dimmed screen, max brightness=bright screen), on 4.9 min brightness=backlight off, max brightness=bright screen; such behavior seems to allow wider dimming range, and it works as expected with CCFL backlights, but breaks normal operation with LED backlight: min brightness=backlight off, max brightness=dimmed screen; if patched drm drivers for LED inversion; min brightness(8)=dimmed screen, max brightness(255)=backlight off - need to set 254 for max brightness or alternetively not use Fn+F9/F10 keys but adjust brightness only via GUI slider |
I can confirm this one, I get this on a converted Chromebook too. I can excape it by terminating the X server and starting another session. If that failed, ctrl-alt-F2 to another VT will bring back a working monitor from this, allowing killing the x session (if you have ctrl-alt-backspace disabled) or other recovery steps. I agree this is serious and a deterrrent to using the applet. Even if it ALWAYS recovers on starting a new session (I have tested one machine only), you still lose your work. We really do need a minimum brightness here. |
FWIW, I this is still relevant and I had a user having set the display off that way (through the applet's slider), and didn't know how to get the screen back on. I think we need either a (configurable) hard value for the minimum if that's something that can actually work reliably across hardware (some hardware will dim all the way to off through the kernel API, some won't), or rather a minimal percentage (e.g. don't go below 5% of the available range or so). We need a setting for that in any case because there really are some people that want very low settings, or even off, so there won't ever be a perfect one-size-fits-all value. I quickly investigated doing so using a percentage minimum, but unfortunately the handling of key shortcuts is kind of separate from the absolute percentage setting, which might require refactoring more code than I found time for. If anybody's interesting in continuing this, here's what I had: https://gist.github.com/cwendling/797796eaffdf8688f1f286b96f637a28 (not that it's necessarily super useful as it might require a lot more refactoring). |
I remembered talking to the Linux kernel community on this one. To them zero meant zero as in off. Now if from a userspace perspective if Mate wanted a configurable minimum, that seems reasonable and fine to me! |
maybe you can use similar solution i used to prevent backlight from going off when set max brightness. RADEON_MAX_BL_LEVEL - 1 note that this is on a system that had CCFL backlight as default, and i upgraded it to LED backlight (didnt ever bothered with BIOS support for the change, it is possible BIOS have some effect on it too), on systems with LED default it may need different kind of change, but in general you get an idea how to patch the driver... |
Same scenario with a Dell Precision 5550:
Given the range of differences across various implementations on how brightness works, IMHO the only reasonable solution here is to have user configurable values:
Ideally we could have a database of such values for various laptops, though this would be a stretch. |
I have a relatively new laptop (Lenovo L450). When I lower the brightness (either via the brightness applet or via function keys) and the backlight reaches zero, the backlight is turned off completely. At that point,
/sys/class/backlight/intel_backlight/brightness
is 0 (the maximum value,/sys/class/backlight/intel_backlight/max_brightness
, is 973. The LCD is still on (something is still visible when inspecting the screen closely), but the screen appears off.This may be a kernel bug or an issue with the hardware/firmware, so if it's specific to this model it may be better to work around it in the kernel.
In Cinnamon (Gnome 3 fork) it is not possible to turn the screen off this way with the brightness slider (lowest value appears to be 9), but it is still possible with the function keys.
I am running a fully up-to-date version of Debian testing (stretch), which includes version 1.10.2-1. I can report the issue in Debian if that is a more appropriate place.
My
lspci
:Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
The text was updated successfully, but these errors were encountered: