git: 4d5697a5022f - main - x11/nvidia-driver, linux-nvidia-libs, nvidia-drm: Update to 550.127.05

From: Kevin Bowling <kbowling_at_FreeBSD.org>
Date: Tue, 29 Oct 2024 18:39:03 UTC
The branch main has been updated by kbowling:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4d5697a5022f9846836a0185bda68557fd6f364b

commit 4d5697a5022f9846836a0185bda68557fd6f364b
Author:     Tomoaki AOKI <junchoon@dec.sakura.ne.jp>
AuthorDate: 2024-10-29 18:24:07 +0000
Commit:     Kevin Bowling <kbowling@FreeBSD.org>
CommitDate: 2024-10-29 18:37:31 +0000

    x11/nvidia-driver, linux-nvidia-libs, nvidia-drm: Update to 550.127.05
    
    Approved by:    blanket, Austin Shafer <ashafer@badland.io>
    PR:             282312
---
 graphics/nvidia-drm-510-kmod/distinfo                     |  6 +++---
 .../files/extra-patch-nvidia-drm-conftest.h}              |  0
 graphics/nvidia-drm-515-kmod/distinfo                     |  4 ++--
 .../files/extra-patch-nvidia-drm-conftest.h}              |  0
 graphics/nvidia-drm-61-kmod/distinfo                      |  4 ++--
 .../files/extra-patch-nvidia-drm-conftest.h               | 14 ++++++++++++++
 graphics/nvidia-drm-kmod/Makefile.common                  |  7 +++++++
 x11/linux-nvidia-libs/Makefile                            | 15 ++++++++++++---
 x11/linux-nvidia-libs/distinfo                            |  6 +++---
 x11/nvidia-driver/Makefile.version                        |  2 +-
 x11/nvidia-driver/distinfo                                |  6 +++---
 11 files changed, 47 insertions(+), 17 deletions(-)

diff --git a/graphics/nvidia-drm-510-kmod/distinfo b/graphics/nvidia-drm-510-kmod/distinfo
index abc709fa60bb..acb84ed393aa 100644
--- a/graphics/nvidia-drm-510-kmod/distinfo
+++ b/graphics/nvidia-drm-510-kmod/distinfo
@@ -1,5 +1,5 @@
-TIMESTAMP = 1727593803
-SHA256 (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 9e2bb3dc93be5da6abe0c78621120e71dfcc0973577c9e63386e9a582501147e
-SIZE (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 143460952
+TIMESTAMP = 1729779540
+SHA256 (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 74557d328ad74f604599ee2df3d42defc86ebe231e7cbe99c860f928f16a0bc3
+SIZE (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 143641432
 SHA256 (freebsd-drm-kmod-drm_v5.10.163_7_GH0.tar.gz) = dbdff8ad8cad8152d1c286b058f1f5114b3672f1a936e13933ce52915b77eaaa
 SIZE (freebsd-drm-kmod-drm_v5.10.163_7_GH0.tar.gz) = 20095338
diff --git a/graphics/nvidia-drm-515-kmod/files/patch-nvidia-drm-conftest.h b/graphics/nvidia-drm-510-kmod/files/extra-patch-nvidia-drm-conftest.h
similarity index 100%
rename from graphics/nvidia-drm-515-kmod/files/patch-nvidia-drm-conftest.h
rename to graphics/nvidia-drm-510-kmod/files/extra-patch-nvidia-drm-conftest.h
diff --git a/graphics/nvidia-drm-515-kmod/distinfo b/graphics/nvidia-drm-515-kmod/distinfo
index beb33eae58d2..d62b49230fa7 100644
--- a/graphics/nvidia-drm-515-kmod/distinfo
+++ b/graphics/nvidia-drm-515-kmod/distinfo
@@ -1,5 +1,5 @@
 TIMESTAMP = 1729926280
-SHA256 (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 9e2bb3dc93be5da6abe0c78621120e71dfcc0973577c9e63386e9a582501147e
-SIZE (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 143460952
+SHA256 (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 74557d328ad74f604599ee2df3d42defc86ebe231e7cbe99c860f928f16a0bc3
+SIZE (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 143641432
 SHA256 (freebsd-drm-kmod-drm_v5.15.160_1_GH0.tar.gz) = b48e104c3437ac6e8a58e734fe943281f43b31d9327d50457bb26d8a2106bf64
 SIZE (freebsd-drm-kmod-drm_v5.15.160_1_GH0.tar.gz) = 26098489
diff --git a/graphics/nvidia-drm-61-kmod/files/patch-nvidia-drm-conftest.h b/graphics/nvidia-drm-515-kmod/files/extra-patch-nvidia-drm-conftest.h
similarity index 100%
rename from graphics/nvidia-drm-61-kmod/files/patch-nvidia-drm-conftest.h
rename to graphics/nvidia-drm-515-kmod/files/extra-patch-nvidia-drm-conftest.h
diff --git a/graphics/nvidia-drm-61-kmod/distinfo b/graphics/nvidia-drm-61-kmod/distinfo
index 8dc4b5369ed2..848238468490 100644
--- a/graphics/nvidia-drm-61-kmod/distinfo
+++ b/graphics/nvidia-drm-61-kmod/distinfo
@@ -1,5 +1,5 @@
 TIMESTAMP = 1729926563
-SHA256 (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 9e2bb3dc93be5da6abe0c78621120e71dfcc0973577c9e63386e9a582501147e
-SIZE (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 143460952
+SHA256 (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 74557d328ad74f604599ee2df3d42defc86ebe231e7cbe99c860f928f16a0bc3
+SIZE (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 143641432
 SHA256 (freebsd-drm-kmod-drm_v6.1.92_2_GH0.tar.gz) = 0c28dc918dc16a103ac93ec8f7521145115e24f7c462595ce4433e1769708122
 SIZE (freebsd-drm-kmod-drm_v6.1.92_2_GH0.tar.gz) = 37101285
diff --git a/graphics/nvidia-drm-61-kmod/files/extra-patch-nvidia-drm-conftest.h b/graphics/nvidia-drm-61-kmod/files/extra-patch-nvidia-drm-conftest.h
new file mode 100644
index 000000000000..2c0524341c4d
--- /dev/null
+++ b/graphics/nvidia-drm-61-kmod/files/extra-patch-nvidia-drm-conftest.h
@@ -0,0 +1,14 @@
+--- nvidia-drm-conftest.h.orig	2024-02-22 01:03:15 UTC
++++ nvidia-drm-conftest.h
+@@ -85,7 +85,11 @@
+ 
+ /* For nv_drm_gem_prime_force_fence_signal */
+ #ifndef spin_is_locked
++#if ((__FreeBSD_version >= 1500000) && (__FreeBSD_version < 1500018)) || (__FreeBSD_version < 1401501)
+ #define spin_is_locked(lock) mtx_owned(lock.m)
++#else
++#define spin_is_locked(lock) mtx_owned(lock)
++#endif
+ #endif
+ 
+ #ifndef rwsem_is_locked
diff --git a/graphics/nvidia-drm-kmod/Makefile.common b/graphics/nvidia-drm-kmod/Makefile.common
index b9dc46449455..1194e9b396dc 100644
--- a/graphics/nvidia-drm-kmod/Makefile.common
+++ b/graphics/nvidia-drm-kmod/Makefile.common
@@ -30,6 +30,10 @@ MAKE_ENV+=	DEBUG_FLAGS=${DEBUG_FLAGS} \
 WRKSRC=		${WRKDIR}/NVIDIA-FreeBSD-${ARCH_SUFX}-${NVIDIA_DISTVERSION}/
 WRKSRC_SUBDIR=	src/nvidia-drm/
 
+.if ${NVVERSION} < 565.00000
+EXTRA_PATCHES+= ${FILESDIR}/extra-patch-nvidia-drm-conftest.h
+.endif #565.00
+
 .if ${NVVERSION} < 555.04202
 EXTRA_PATCHES+= ${FILESDIR}/extra-patch-nvidia-drm-freebsd-lkpi.c
 .endif
@@ -39,6 +43,9 @@ post-install:
 	${INSTALL_DATA} ${WRKDIR}/20-nvidia-drm-outputclass.conf ${STAGEDIR}${PREFIX}/share/X11/xorg.conf.d/
 
 post-patch:
+	# Workaround for LLVM/Clang19
+	${REINPLACE_CMD} -e '/DRMKMODDIR.*\/linuxkpi\/dummy\/include/d' \
+		${WRKSRC}/Makefile
 	# We should support -CURRENT: kill the check (first #if __FreeBSD_version)
 	linenum=$$(${SED} -ne '/^#if __FreeBSD_version/ { = ; q ; }' \
 			${WRKSRC}/../nvidia/nv-freebsd.h) ; ${REINPLACE_CMD} \
diff --git a/x11/linux-nvidia-libs/Makefile b/x11/linux-nvidia-libs/Makefile
index 3fe7d7798371..a20dcac257e7 100644
--- a/x11/linux-nvidia-libs/Makefile
+++ b/x11/linux-nvidia-libs/Makefile
@@ -129,7 +129,11 @@ LINUX32_LIBS+=	libnvidia-compiler.so.${PORTVERSION}
 .endif
 
 
-.if ${NVVERSION} >= 550.00000 # 550.00
+.if ${NVVERSION} >= 565.00000 # 565.00
+LINUX_LIBS+=	libnvidia-egl-wayland.so.1.1.17
+LINUX_LINKS+=	libnvidia-egl-wayland.so.1.1.17 libnvidia-egl-wayland.so.1
+PLIST_RE+=	'\,${LINUXBASE},s/(libnvidia-egl-wayland\.so)\.X/\1.1.1.17/'
+.elif ${NVVERSION} >= 550.00000 # 550.00
 LINUX_LIBS+=	libnvidia-egl-wayland.so.1.1.13
 LINUX_LINKS+=	libnvidia-egl-wayland.so.1.1.13 libnvidia-egl-wayland.so.1
 PLIST_RE+=	'\,${LINUXBASE},s/(libnvidia-egl-wayland\.so)\.X/\1.1.1.13/'
@@ -290,7 +294,12 @@ LINUX32_LIBS+=  libnvidia-gpucomp.so.${PORTVERSION}
 .else
 PLIST_RE+=	'\,${LINUXBASE}.*libnvidia-gpucomp\.so,d'
 .endif # 545.00
-.if ${NVVERSION} >= 550.00000 # 550.00
+.if ${NVVERSION} >= 565.00000 # 565.00
+LINUX_LIBS+=	libnvidia-egl-gbm.so.1.1.2
+LINUX_LINKS+=	libnvidia-egl-gbm.so.1.1.2 libnvidia-egl-gbm.so.1 \
+		libnvidia-egl-gbm.so.1.1.2 libnvidia-egl-gbm.so
+PLIST_RE+=	'\,${LINUXBASE},s/(libnvidia-egl-gbm\.so)\.X/\1.1.1.2/'
+.elif ${NVVERSION} >= 550.00000 # 550.00
 LINUX_LIBS+=	libnvidia-egl-gbm.so.1.1.1
 LINUX_LINKS+=	libnvidia-egl-gbm.so.1.1.1 libnvidia-egl-gbm.so.1 \
 		libnvidia-egl-gbm.so.1.1.1 libnvidia-egl-gbm.so
@@ -300,7 +309,7 @@ LINUX_LIBS+=	libnvidia-egl-gbm.so.1.1.0
 LINUX_LINKS+=	libnvidia-egl-gbm.so.1.1.0 libnvidia-egl-gbm.so.1 \
 		libnvidia-egl-gbm.so.1.1.0 libnvidia-egl-gbm.so
 PLIST_RE+=	'\,${LINUXBASE},s/(libnvidia-egl-gbm\.so)\.X/\1.1.1.0/'
-.endif # 550.00
+.endif # 565.00
 .if ${NVVERSION} >= 525.08902 # 525.89.02
 LINUX_LIBS+=	libnvoptix.so.${PORTVERSION} \
 		libnvidia-nvvm.so.${PORTVERSION} \
diff --git a/x11/linux-nvidia-libs/distinfo b/x11/linux-nvidia-libs/distinfo
index 2deda76487a2..6141edfc2152 100644
--- a/x11/linux-nvidia-libs/distinfo
+++ b/x11/linux-nvidia-libs/distinfo
@@ -1,6 +1,6 @@
-TIMESTAMP = 1727593735
-SHA256 (NVIDIA-Linux-x86_64-550.120.run) = 801928274753ccce7627098ea078cc37070ddae04de3aa084591c05fc7035697
-SIZE (NVIDIA-Linux-x86_64-550.120.run) = 307064664
+TIMESTAMP = 1729779155
+SHA256 (NVIDIA-Linux-x86_64-550.127.05.run) = d384f34f5d2a896bd7536d3deb6a6d973d8094a3ad485a1c2ee3bf5192086ae9
+SIZE (NVIDIA-Linux-x86_64-550.127.05.run) = 307139930
 SHA256 (NVIDIA-Linux-x86_64-470.161.03.run) = 5da82a7f8c76e781e7d7f0be7b798db4d344f26bd4facf9abcf3c71c71fe7640
 SIZE (NVIDIA-Linux-x86_64-470.161.03.run) = 272397700
 SHA256 (NVIDIA-Linux-x86_64-390.154.run) = f4420280c55210964c008d5b724f2615845d47ad4c9c05d8ed26a62fc6331f7c
diff --git a/x11/nvidia-driver/Makefile.version b/x11/nvidia-driver/Makefile.version
index 51a725215671..03d4d5525224 100644
--- a/x11/nvidia-driver/Makefile.version
+++ b/x11/nvidia-driver/Makefile.version
@@ -1,4 +1,4 @@
 # NVIDIA Distversion
 #
 # This will be included from x11/nvidia-driver and the nvidia-drm port
-NVIDIA_DISTVERSION = 550.120
+NVIDIA_DISTVERSION = 550.127.05
diff --git a/x11/nvidia-driver/distinfo b/x11/nvidia-driver/distinfo
index 21ddd102bf53..8243d14c80f8 100644
--- a/x11/nvidia-driver/distinfo
+++ b/x11/nvidia-driver/distinfo
@@ -1,6 +1,6 @@
-TIMESTAMP = 1727593598
-SHA256 (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 9e2bb3dc93be5da6abe0c78621120e71dfcc0973577c9e63386e9a582501147e
-SIZE (NVIDIA-FreeBSD-x86_64-550.120.tar.xz) = 143460952
+TIMESTAMP = 1729779540
+SHA256 (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 74557d328ad74f604599ee2df3d42defc86ebe231e7cbe99c860f928f16a0bc3
+SIZE (NVIDIA-FreeBSD-x86_64-550.127.05.tar.xz) = 143641432
 SHA256 (NVIDIA-FreeBSD-x86_64-470.161.03.tar.xz) = 54f87e6cadc4aedebc4f862e3d25657fddb867ddc3fe01ad06c9d54bcfa8d607
 SIZE (NVIDIA-FreeBSD-x86_64-470.161.03.tar.xz) = 99719576
 SHA256 (NVIDIA-FreeBSD-x86_64-390.154.tar.gz) = 5994c77c3510a4a89076ecf2bf402f1da635b250cca07655efc913f2a94bee84