Severely distorted image on a laptop with Ubuntu 21.04. Nvidia 840m. 470.57.02 (and older) drivers

I’m trying to revive a slightly old Lenovo Z70-80. I haven’t used it for a month or so, downloaded all the latest updates on Monday and something broke for the first time in years. I even tried a complete re-install (it was time for that - I upgraded to the last couple of Ubuntu versions), however, that didn’t help.

I killed gdm and started a root xserver session with logverbose 6. Here’s the bug report:
nvidia-bug-report.log.gz (367.2 KB)
Please tell me if I did it correctly.

Here’s a video that shows what happens on the screen. Notice that the pixels from the middle of the screen have been moved to the side. The entire screen is jittering as if it’s tearing multiple times per frame. I’ve never seen it behave like that. It was bad when things broke before (boot to black screen or nasty tearing), but not THAT bad.


Everything looks fine in GRUB and BIOS. There’s also a second option with an older kernel in GRUB that boots into a Wayland session which uses Intel’s integrated GPU. It works fine. I didn’t check, but I guess that’s what the Ubuntu installer was using, since it worked fine as well. However, I really need the 840M.

I’ve added the graphics-dirvers ppa immediately tried most if not all available driver versions, purging all nvidia and libnvidia stuff between them and rebooting.

According to nvidia-settings, sync is enabled. I am using the high performance mode. Sadly, this older laptop does not allow me to disable the integrated GPU in BIOS.

nouveau is disabled and blacklisted.

manvydas@manvydas-Lenovo-Z70-80:~$ gpu-manager | grep nouveau  
Is nouveau loaded? no
Is nouveau blacklisted? yes

I tried an xorg config file that helped me before (I guess, more than a year or two ago), but it didn’t do anything this time:

Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"
EndSection

Section "Device"
    Identifier "intel"
    Driver "modesetting"
    BusID "PCI:0@0:2:0"
    Option "AccelMethod" "None"
EndSection

Section "Screen"
    Identifier "intel"
    Device "intel"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:4@0:0:0"
    Option "ConstrainCursor" "off"
EndSection

Section "Screen"
    Identifier "nvidia"
    Device "nvidia"
    Option "AllowEmptyInitialConfiguration" "on"
    Option "IgnoreDisplayDevices" "CRT"
EndSection

Rebuilding the modules has helped me before, but it didn’t work either:

sudo dkms remove nvidia/470.57.02 --all
sudo dkms install --force nvidia/470.57.02 -k $(uname -r)
sudo update-initramfs -u
sudo sync
sudo reboot

I haven’t done this in quite a while, since things were usually working out of the box with drivers from the graphics-drivers ppa, so I may have missed something obvious. I’ll appreciate any advice. Thanks.

Well, I kept on trying an here’s what I’ve found out. Everything works flawlessly using Linux 5.11.0-16-generic. Looks like a regression of some sort in Linux 5.11.0-25-generic.

Should I report this as a bug to Ubuntu?

Same here on Arch/Ubuntu20-21/Fedora32-34.

Ooops, I forgot to post it here. Turns out, we’re running into a known bug.

Here’s the Ubuntu tracker:

And here’s the original freedesktop bug that the Ubuntu bug depends on:

1 Like