On FreeBSD 14-RC4, graphics/nvidia-drm-515-kmod builds, but it fails to load with the error message: KLD nvidia-drm.ko: depends on linuxkpi_gplv2 - not available or version mismatch linker_load_file: /boot/modules/nvidia-drm.ko - unsupported file type linuxkpi_gplv2 was removed from the drm-515-kmod package with change 46b49a44fb98c4aa96b6cc259b13d54eb1a9a036 So, there probably needs some logic to use correct includes when building for drm-515.
Seems that if one removes the MODULE_DEPEND for linuxkpi_gplv2, things seem to load. So, it might be enough with version checking since gplv2 exits for 510 kmod.
I have the same issue with nvidia-drm-515-kmod on FreeBSD 14-STABLE. Is there any workaround for it? I tried use linuxkpi_gplv2.ko from drm-510-kmod together with nvidia-drm-515-kmod but got kernel panic.
Fix here, sorry for the breakage: https://reviews.freebsd.org/D42484
A commit in branch main references this bug: URL: https://cgit.FreeBSD.org/ports/commit/?id=0a0e141da5b584e00c498947e596b957bd40db94 commit 0a0e141da5b584e00c498947e596b957bd40db94 Author: Austin Shafer <ashafer@badland.io> AuthorDate: 2023-11-07 08:26:48 +0000 Commit: Gleb Popov <arrowd@FreeBSD.org> CommitDate: 2023-11-07 08:35:19 +0000 graphics/nvidia-drm-515-kmod: Remove dependency on linuxkpi_gplv2.ko This fixes a failure on module load for nvidia-drm.ko as a result of linuxkpi_gplv2.ko being removed from drm-kmod in 5.15. For now we just remove the dependency in the nvidia-drm 515 port to unbreak things, I'll create a longer-term upstream fix. PR: 274910 Reviewed by: arrowd Differential Revision: https://reviews.freebsd.org/D42484 graphics/nvidia-drm-515-kmod/Makefile | 2 +- .../files/patch-nvidia-drm-freebsd-lkpi.c (new) | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-)