commit 8ac26debe8c14e188ccaadf1c542182fafec5a82
Author: Jan Rękorajski <[email protected]>
Date:   Sun Mar 26 10:30:11 2017 +0200

    - up to 340.102
    - added build fix for kernel 4.10

 linux-4.10.patch                           | 38 ++++++++++++++++++++++++++++++
 xorg-driver-video-nvidia-legacy-340xx.spec |  8 ++++---
 2 files changed, 43 insertions(+), 3 deletions(-)
---
diff --git a/xorg-driver-video-nvidia-legacy-340xx.spec 
b/xorg-driver-video-nvidia-legacy-340xx.spec
index 6d4f332..3daa064 100644
--- a/xorg-driver-video-nvidia-legacy-340xx.spec
+++ b/xorg-driver-video-nvidia-legacy-340xx.spec
@@ -32,15 +32,15 @@ Summary(hu.UTF-8):  Linux meghajtók nVidia GeForce/Quadro 
chipekhez
 Summary(pl.UTF-8):     Sterowniki do kart graficznych nVidia GeForce/Quadro
 Name:          %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
 # when updating version here, keep nvidia-settings.spec in sync as well
-Version:       340.101
+Version:       340.102
 Release:       %{rel}%{?_pld_builder:%{?with_kernel:@%{_kernel_ver_str}}}
 Epoch:         1
 License:       nVidia Binary
 Group:         X11
 Source0:       
http://us.download.nvidia.com/XFree86/Linux-x86/%{version}/NVIDIA-Linux-x86-%{version}.run
-# Source0-md5: b2b33b50cf375ccba7d3b959b9f509ec
+# Source0-md5: 61aad6a98238bc61466e6a9e392cfd08
 Source1:       
http://us.download.nvidia.com/XFree86/Linux-x86_64/%{version}/NVIDIA-Linux-x86_64-%{version}-no-compat32.run
-# Source1-md5: dd1a25ab34b7855d533474f3e8f3e868
+# Source1-md5: 81e720487caa2823586b32659da9acc1
 Source2:       xorg-driver-video-nvidia-xinitrc.sh
 Source3:       gl.pc.in
 Source4:       10-nvidia.conf
@@ -48,6 +48,7 @@ Source5:      10-nvidia-modules.conf
 Patch0:                X11-driver-nvidia-GL.patch
 Patch1:                X11-driver-nvidia-desktop.patch
 Patch2:                linux-4.0.patch
+Patch3:                linux-4.10.patch
 URL:           http://www.nvidia.com/object/unix.html
 BuildRequires: rpmbuild(macros) >= 1.701
 %{?with_kernel:%{expand:%buildrequires_kernel 
kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}}
@@ -250,6 +251,7 @@ rm -rf NVIDIA-Linux-x86*-%{version}*
 %patch0 -p1
 %patch1 -p1
 %patch2 -p1
+%patch3 -p1
 echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> 
kernel/Makefile.kbuild
 
 %build
diff --git a/linux-4.10.patch b/linux-4.10.patch
new file mode 100644
index 0000000..76f5274
--- /dev/null
+++ b/linux-4.10.patch
@@ -0,0 +1,38 @@
+diff --git a/kernel/nv-linux.h b/kernel/nv-linux.h
+index e7068e3..3ac3c0b 100644
+--- a/kernel/nv-linux.h
++++ b/kernel/nv-linux.h
+@@ -270,7 +270,7 @@ RM_STATUS nvos_forward_error_to_cray(struct pci_dev *, 
NvU32,
+ 
+ extern int nv_pat_mode;
+ 
+-#if !defined(NV_VMWARE) && defined(CONFIG_HOTPLUG_CPU)
++#if !defined(NV_VMWARE) && defined(CONFIG_HOTPLUG_CPU) && (LINUX_VERSION_CODE 
< KERNEL_VERSION(4, 10, 0))
+ #define NV_ENABLE_HOTPLUG_CPU
+ #include <linux/cpu.h>              /* CPU hotplug support              */
+ #include <linux/notifier.h>         /* struct notifier_block, etc       */
+diff --git a/kernel/nv-pat.c b/kernel/nv-pat.c
+index a725533..91070e0 100644
+--- a/kernel/nv-pat.c
++++ b/kernel/nv-pat.c
+@@ -210,14 +210,20 @@ nvidia_cpu_callback(struct notifier_block *nfb, unsigned 
long action, void *hcpu
+ 
+     switch (action)
+     {
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0)
+         case CPU_DOWN_FAILED:
++#endif
+         case CPU_ONLINE:
+             if (cpu == (NvUPtr)hcpu)
+                 nv_setup_pat_entries(NULL);
+             else
+                 NV_SMP_CALL_FUNCTION(nv_setup_pat_entries, hcpu, 1);
+             break;
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0)
+         case CPU_DOWN_PREPARE:
++#else
++        case CPU_DOWN_PREPARE_FROZEN:
++#endif
+             if (cpu == (NvUPtr)hcpu)
+                 nv_restore_pat_entries(NULL);
+             else
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/xorg-driver-video-nvidia-legacy-340xx.git/commitdiff/8ac26debe8c14e188ccaadf1c542182fafec5a82

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to