I feel your pain. I always have problems trying to figure out how to get rid of tearing on my laptops that have both an Nvidia dGPU (Dedicated GPU) and the iGPU (Integrated GPU).
I'm going to take a stab in the dark and guess that you're system is a PRIME system, in which case the composition pipeline options will not be available (even adding them manually to your xorg.conf file won't work - it'll probably just make your screen go dark).
I think what you're looking for (again, just guessing) is PRIME Synchronization - this is Nvidia's new way of syncing screens.
Try this:
- Create a file in your
/etc/modprobe.d
directory called zz-nvidia-tearing.conf
.
- Add the following line to it:
options nvidia_387_drm modeset=1
(change "387" to your driver version).
- From the terminal: sudo update-initramfs -u
- Reboot.
- Check is PRIME sync is enabled:
xrandr --prop | less
You should see something like:
Screen 0: minimum 8 x 8, current 3840 x 1080, maximum 16384 x 16384
eDP-1-1 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 309mm x 174mm
EDID:
00ffffffffffff0030e4210500000000
001a0104951f1178ea9d35945c558f29
1e505400000001010101010101010101
0101010101012e3680a070381f403020
350035ae1000001a542b80a070381f40
3020350035ae1000001a000000fe004c
4720446973706c61790a2020000000fe
004c503134305746362d535042360075
PRIME Synchronization: 1
The important line is the last line. If, for some reason, your PRIME sync still isn't enabled (i.e. set to "1"), then try editing the last line of your /etc/modprobe.d/nvidia-graphics-drivers.conf
- change it to:
options nvidia_387_drm modeset=1
(again, obviously changing "387" to the version of your installed Nvidia driver).
Don't forget to run:
sudo update-initramfs -u
after you make any changes to any file in /etc/modprobe.d
.
If that still doesn't work (which it should, so long as you're using Nvidia driver 370 or higher), then you can try adding the following to your GRUB_CMDLINE_LINUX_DEFAULT
in /etc/default/grub
:
nvidia-drm.modeset=1
I don't know what your GRUB_CMDLINE_LINUX_DEFAULT looks like, but after you add the line above, it could look something like this:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nvidia-drm.modeset=1"
I find it astonishing that Nvidia do not enable PRIME Sync by default on hardware the supports it. The reason given is because it doesn't play nicely with SLI - but how many Linux users actually use SLI? I have yet to see any.
If you have any more questions, ask away, I'll try to answer them.
Good luck!