commit 33c6c2a5d509b206934a43fd0e0bc655e2550e56
Author: Łukasz Wojniłowicz <lukasz.wojnilowicz(a)gmail.com>
Date: Thu Nov 9 18:53:50 2023 +0100
Fix build on kernel-6.6.1
kernel-6.6.1.patch | 14 ++++++++++++++
nvidia-340xx-kmod.spec | 7 ++++++-
2 files changed, 20 insertions(+), 1 deletion(-)
---
diff --git a/kernel-6.6.1.patch b/kernel-6.6.1.patch
new file mode 100644
index 0000000..fec2e28
--- /dev/null
+++ b/kernel-6.6.1.patch
@@ -0,0 +1,14 @@
+diff -Naur a/kernel/nv-drm.c b/kernel/nv-drm.c
+--- a/kernel/nv-drm.c 2023-11-09 18:41:02.535583785 +0100
++++ b/kernel/nv-drm.c 2023-11-09 18:41:37.916798976 +0100
+@@ -277,8 +277,9 @@
+
+ .ioctls = nv_drm_ioctls,
+ .num_ioctls = ARRAY_SIZE(nv_drm_ioctls),
+-
++#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 6, 0)
+ .prime_handle_to_fd = drm_gem_prime_handle_to_fd,
++#endif
+ #if defined(NV_DRM_DRIVER_HAS_GEM_PRIME_CALLBACKS)
+ .gem_prime_export = nv_drm_gem_prime_export,
+ .gem_prime_get_sg_table = nv_drm_gem_prime_get_sg_table,
diff --git a/nvidia-340xx-kmod.spec b/nvidia-340xx-kmod.spec
index f874e08..1f1a3b1 100644
--- a/nvidia-340xx-kmod.spec
+++ b/nvidia-340xx-kmod.spec
@@ -12,7 +12,7 @@ Name: nvidia-340xx-kmod
Epoch: 1
Version: 340.108
# Taken over by kmodtool
-Release: 26%{?dist}
+Release: 27%{?dist}
Summary: NVIDIA display driver kernel module
Group: System Environment/Kernel
License: Redistributable, no modification permitted
@@ -23,6 +23,7 @@ Patch0: import-files-from-390.157.patch
Patch1: fix-build-issues.patch
Patch2: kernel-6.3.1.patch
Patch3: kernel-6.5.2.patch
+Patch4: kernel-6.6.1.patch
BuildRequires: elfutils-libelf-devel
BuildRequires: gcc
@@ -53,6 +54,7 @@ tar --use-compress-program xz -xf
%{_datadir}/%{name}-%{version}/%{name}-%{versi
%patch1 -p1
%patch2 -p1
%patch3 -p1
+%patch4 -p1
for kernel_version in %{?kernel_versions} ; do
cp -a kernel _kmod_build_${kernel_version%%___*}
@@ -81,6 +83,9 @@ done
%{?akmod_install}
%changelog
+* Thu Nov 09 2023 Łukasz Wojniłowicz <lukasz.wojnilowicz(a)gmail.com> - 1:340.108-27
+- Fix build on kernel-6.6.1
+
* Mon Sep 11 2023 Łukasz Wojniłowicz <lukasz.wojnilowicz(a)gmail.com> - 1:340.108-26
- Fix build on kernel-6.5.2
Show replies by date