1

Is there a software way to ask the video driver to turn a display physically off and on?

Some times (often) my laptop built-in display backlight won't turn on after the laptop wakes up from suspend. It (the backlight) has also just turned off spontaneously once. In both kinds of cases I have to switch the computer off, detach the power cord and the battery, attach them back and turn it on to actually reset the display, it won't turn the back light back on without this whole procedure. xbacklight doesn't help nor do the brightness up/down buttons on the keyboard (although both work just fine normally). Disabling/enabling the display in the display settings helps neither. This makes me curious if there is a way to ask the driver (Intel in my case) or X to send some kind of a low-level switch-off command to the display to turn it completely off (like the power button on discrete monitors does) and back on, perhaps a thing like this could help...

UPDATE: I actually believe I'm using the Intel driver as sudo lshw -c video says configuration: driver=i915 latency=0 among everything else. I'm not sure but I think I had been using the generic driver until recently (I've just formatted the hard drive and set up a new system from scratch some days ago and didn't actually take a look what driver was used in the old one) and there was the same problem with it. In fact this happens when I run Windows 7 as well so I doubt it's a driver problem. It even affects the pre-OS BIOS POST boot stage (if I reboot after the baclkight failure even the boot-time manufacturer logo is almost invisible). I'm just curious if there is a software way to try to hard-reset the display w/o having to actually unpower it completely by detaching the battery. The laptop is DELL E5500, it's pretty old but works really great otherwise, especially after the HDD-to-SSD upgrade.

  • Sounds bad. I would suggest studying the system log in such cases and look, whether they protocol which indicates a repeated event, probably causing this. – user unknown Feb 3 '18 at 6:19
  • It is known using frame-buffer based video drivers instead of the the ones for Intel reduces functionality, including backlight and external monitors not working. Are you sure you are using the Intel one? – Rui F Ribeiro Feb 3 '18 at 14:31
  • @RuiFRibeiro Yes, I believe I'm using the Intel driver. I've updated the question with more details. – Ivan Feb 4 '18 at 2:50
2

You could install the xset package and try:

xset dpms force off

And if that does not work, maybe yet before it:

xset +dpms
0

This could be an interaction between many system components, a few I can list is: the distributor's kernel version, the kernel's i915 module, the X11 version and the drm driver. Ideally you would be looking for a bug listed against some of those components that would show the best workaround.

Is it actually working? Can you actually log in to the laptop from another host with the display off? Can you see something similar in the dmesg output?

[drm:intel_enable_lvds [i915]] *ERROR* timed out waiting for panel to power on

Some versions of the drm driver was known to have issues. While it was in this state, I could make it work with xrandr toggling the output. Check the output without arguments, there might be several, and probably the internal one has a name starting with LVDS. In my case it's LVDS-1, and I had some luck with running this script, assigned to a hotkey, after login:

#!/bin/sh
sleep 1; DISPLAY=:0 xrandr --output LVDS-1 --off
sleep 1; DISPLAY=:0 xrandr --output LVDS-1 --auto

Update: now rereading the part that it also turns off spontaneously on its own, it could suggest that it's a completely caused by hardware, and perhaps there's nothing any software driver can do - is, by any chance your laptop model prone to those overheating/intermittently failing BGA issues? That could warrant a hardware fixing/replacement.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.