Comment 277 for bug 1887190

Revision history for this message
Pedro Ribeiro (pedrib) wrote :

Again my apologies to everyone for hijacking this thread, But since people are asking, and I was able to solve the backlight problem after days of pain, here are the instructions. Two caveats though:

- you need to have the laptop in "Discrete" mode in the BIOS (in my experience, Hybrid mode gives little battery life advantage, even in Windows)
- the instructions below are for Debian, but the only different thing to have in mind is the /experimental release in the apt install command, which should be adapted to the Ubuntu release you want to install the drivers from

1. make sure that you remove all nvidia stuff:
apt --purge remove nvidia*
(this includes any nvidia configuration files in /etc/X11/xorg.conf.d)

2. install the proprietary nvidia driver version you want (replace experimental with the target release)
sudo apt install libegl-nvidia0/experimental libgl1-nvidia-glvnd-glx/experimental libglx-nvidia0/experimental libnvidia-eglcore/experimental libnvidia-glcore/experimental libnvidia-ml1/experimental nvidia-alternative/experimental nvidia-driver/experimental nvidia-driver-bin/experimental nvidia-driver-libs/experimental nvidia-egl-common/experimental nvidia-egl-icd/experimental nvidia-kernel-dkms/experimental nvidia-kernel-support/experimental nvidia-modprobe/experimental nvidia-vdpau-driver/experimental xserver-xorg-video-nvidia/experimental libgles-nvidia1/experimental libgles-nvidia2/experimental nvidia-vulkan-icd/experimental libnvidia-cfg1/experimental libcuda1/experimental libnvcuvid1/experimental libnvidia-encode1/experimental nvidia-opencl-icd/experimental nvidia-smi/experimental libnvidia-cbl/experimental libnvidia-rtcore/experimental nvidia-cuda-mps/experimental libnvidia-ptxjitcompiler1/experimental libnvidia-compiler/experimental libnvidia-glvkspirv/experimental nvidia-settings

3. create a file /etc/X11/xorg.conf.d/21-nvidia-brightness.conf with the following contents:
Section "OutputClass"
    Identifier "nvidia"
    MatchDriver "nvidia-drm"
    Driver "nvidia"
    Option "RegistryDwords" "EnableBrightnessControl=1"
EndSection

4. reboot and backlight control should be working!