NVIDIA – Possible Fix for 6.0?
After more testing, I found a potential fix for the ‘Kernel 6.0-rc0’ compile problem..
In NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-drm/nvidia-drm-helper.c:
Around Line 30:
add:
#include <drm/drm_framebuffer.h>
And the compile completes successfully:
………………………..
ld -r -o /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-modeset/nv-modeset-interface.o /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-modeset/nvidia-modeset-linux.o /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-modeset/nv-kthread-q.o
MODPOST /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/Module.symvers
CC [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-drm.mod.o
LD [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-drm.ko
CC [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-modeset.mod.o
LD [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-modeset.ko
CC [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-peermem.mod.o
LD [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-peermem.ko
CC [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-uvm.mod.o
LD [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia-uvm.ko
CC [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia.mod.o
LD [M] /home/rgadsdon/NVIDIA-Linux-x86_64-515.65.01/kernel/nvidia.ko
make[1]: Leaving directory ‘/usr/src/linux-6.0-rc0’
I have tested this with KDE (Fedora 36) and VMware, 4K video playback, etc, and everything seems to be working OK..
Warning…. This fix was devised using logic, not driver programming expertise, so may not be completely ‘correct’! Hopefully someone who has the required knowledge will be able to come up with a valid one.. Use at your own risk!
Robert Gadsdon. August 12th 2022.
Tested with openSUSE Tumbleweed – OK.
Tested with OpenSUSE Tumbleweed + NVIDIA Telsa M40 + Geforce GT130
works fine with 515.65.01
Thanks a lot for investigating and this fix from my side as well.
I can confirm that this works using Manjaro Linux 22.0.0, with Nvidia driver 515.65.01 and kernel 6.0.0-rc2.
There is a better fix, see
https://github.com/NVIDIA/open-gpu-kernel-modules/pull/350
The Nvidia folks propose to have that include rather in kernel/nvidia-drm/nvidia-drm-helper.h than in kernel/nvidia-drm/nvidia-drm-helper.c .
See
https://github.com/NVIDIA/open-gpu-kernel-modules/pull/350
Actually they propose to have it in kernel-open/nvidia-drm/nvidia-drm-helper.h rather than kernel/nvidia-drm/nvidia-drm-helper.h. Since it doesn’t work for me with kernel-open, maybe you might try it in kernel folder.
~/kernel-open in the ‘open source’ tree is the equivalent of ~/kernel in the NVIDIA source tree..
RG.