Tearing on 390 KUbuntu 17.10 K1100M Optimus?

I have a weird problem I’d like help with. I’m using NVidia drivers + Intel drivers on my W540 Lenovo laptop. It seems like in the middle of the screen, when the screen must update fairly often, there is a weird tearing as best as I can tell in the center. It’s almost like the screen is split in half from the left side to the right.

This usually happens during a video or if I’m scrolling real fast in Chrome or Firefox. It doesn’t seem to make a difference if I have an external monitor or not.

Are there any ideas on this one?
nvidia-bug-report.log.gz (140 KB)

Prime sync
To get rid of tearing, use kernel parameter

nvidia-drm.modeset=1

In case of Ubuntu, you might have to add/alter a file in /etc/modprobe.d/ containing

options nvidia_XXX_drm modeset=1

with XXX being the major version of the installed nvidia driver.
After that, run
update-initramfs -u

D’oh forgot that. It does make tearing better. I’ll report if it’s fixed tomorrow when I go back to work on my 3 external monitors.

Ok still having issues. It’s not as obvious but when I use Chrome and am scrolling on Facebook, I can see a difference. I see tearing across the image in the center.

I’m running 3 external monitors and 1 laptop display. The settings I have are configured for the internal and one external using Intel and the other 2 external ones on NVidia from my BIOS config and NVidia settings.

Thoughts?

Please run nvidia-bug-report.sh as root and attach the tar.gz file it creates to your post.
In case of external displays connected directly to the nvidia gpu, use option ForceCompositionPipeline.

Tried and still no difference. Bug report attached to original post.

Is tearing on the internal panel, the external, or both?
The external panels have a native resolution of 1680x1050 but you run them at 1920x1080, so the display scales. Tried running them at their native resolution to rule out tearing resulting from display scaler?

External mainly. I think the internal and one Intel external just lag a bit.

I just tried native on all monitors, and nothing.

Thanks for the help on this.

Maybe also look into the kwin direction:
[url]VSync issues/Tearing in KWin with composite enabled - Linux - NVIDIA Developer Forums

Maybe. I think it happens on Gnome as well.

modeset=1 can only help with tearing on the outputs attached to the intel card.

If you are seeing tearing on other screens, try forcing pipeline composition perhaps (it’s a per-output setting in the nvidia control panel under advanced, but you’ll only see it as an option for outputs connected to the nvidia card). I think how much effect this has depends on the compositor. On my laptops it gets rid of tearing when using xfce (and it’s quite bad otherwise). When I use Cinnamon on Ubuntu 17.10 I have no tearing at all, even without using forced pipeline composition. I have a W520 and a P50. I haven’t put Cinnamon on the W520, it runs either gnome or xfce, and my observations are valid for both laptops (for the W520, I believe the VGA output is connected to the intel card, but I use the Display Port which is connected to the Quadro card).

Hmm. I’m not sure about the DE, as Gnome seems to have the same problem.

I just went to using the Intel card for now on my 3 external monitors (better anyway for posture since my monitors are at eye level). Unless a fix comes out or anything I’ll just leave the loop closed.

It seems the NVidia drivers may just not be as developed as the Intel ones, especially not supporting Wayland.