]> git.pld-linux.org Git - packages/xorg-driver-video-nvidia-legacy-340xx.git/commitdiff
- rel 4 auto/th/xorg-driver-video-nvidia-legacy-340xx-340.102-4
authorJan Rękorajski <baggins@pld-linux.org>
Tue, 1 Aug 2017 08:25:02 +0000 (10:25 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Tue, 1 Aug 2017 08:25:02 +0000 (10:25 +0200)
- fix building with kernel 4.12

linux-4.12.patch [new file with mode: 0644]
xorg-driver-video-nvidia-legacy-340xx.spec

diff --git a/linux-4.12.patch b/linux-4.12.patch
new file mode 100644 (file)
index 0000000..87c50d6
--- /dev/null
@@ -0,0 +1,95 @@
+--- kernel/conftest.sh.orig    2017-07-04 19:34:18.849964147 +0200
++++ kernel/conftest.sh 2017-07-04 19:40:00.084349448 +0200
+@@ -362,7 +362,11 @@
+             # Determine if the set_memory_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_memory_uc(void) {
+                 set_memory_uc();
+             }"
+@@ -375,7 +379,11 @@
+             # Determine if the set_memory_array_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_memory_array_uc(void) {
+                 set_memory_array_uc();
+             }"
+@@ -388,7 +396,11 @@
+             # Determine if the set_pages_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_pages_uc(void) {
+                 set_pages_uc();
+             }"
+--- kernel/uvm/conftest.sh.orig        2017-07-04 19:41:43.317660686 +0200
++++ kernel/uvm/conftest.sh     2017-07-04 19:40:23.248644401 +0200
+@@ -362,7 +362,11 @@
+             # Determine if the set_memory_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_memory_uc(void) {
+                 set_memory_uc();
+             }"
+@@ -375,7 +379,11 @@
+             # Determine if the set_memory_array_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_memory_array_uc(void) {
+                 set_memory_array_uc();
+             }"
+@@ -388,7 +396,11 @@
+             # Determine if the set_pages_uc() function is present.
+             #
+             CODE="
+-            #include <asm/cacheflush.h>
++            #if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++                #include <asm/set_memory.h>
++            #else
++                #include <asm/cacheflush.h>
++            #endif
+             void conftest_set_pages_uc(void) {
+                 set_pages_uc();
+             }"
+--- kernel/nv-vm.c.orig        2017-07-04 20:01:37.098802679 +0200
++++ kernel/nv-vm.c     2017-07-04 20:02:23.720384972 +0200
+@@ -13,6 +13,10 @@
+ #include "nv.h"
+ #include "nv-linux.h"
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 12, 0)
++    #include <asm/set_memory.h>
++#endif
++
+ static inline void nv_set_contig_memory_uc(nv_pte_t *page_ptr, NvU32 num_pages)
+ {
+     if (nv_update_memory_types)
index 2f938281f09b6864b2035bde511c14f893e89a16..ee18c084776647000843b64dd3d4df8057248739 100644 (file)
@@ -25,7 +25,7 @@ exit 1
 
 %define                no_install_post_check_so 1
 
 
 %define                no_install_post_check_so 1
 
-%define                rel     3
+%define                rel     4
 %define                pname   xorg-driver-video-nvidia-legacy-340xx
 Summary:       Linux Drivers for nVidia GeForce/Quadro Chips
 Summary(hu.UTF-8):     Linux meghajtók nVidia GeForce/Quadro chipekhez
 %define                pname   xorg-driver-video-nvidia-legacy-340xx
 Summary:       Linux Drivers for nVidia GeForce/Quadro Chips
 Summary(hu.UTF-8):     Linux meghajtók nVidia GeForce/Quadro chipekhez
@@ -50,6 +50,7 @@ Patch1:               X11-driver-nvidia-desktop.patch
 Patch2:                linux-4.0.patch
 Patch3:                linux-4.10.patch
 Patch4:                linux-4.11.patch
 Patch2:                linux-4.0.patch
 Patch3:                linux-4.10.patch
 Patch4:                linux-4.11.patch
+Patch5:                linux-4.12.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}}
 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}}
@@ -254,6 +255,7 @@ rm -rf NVIDIA-Linux-x86*-%{version}*
 %patch2 -p1
 %patch3 -p1
 %patch4 -p0
 %patch2 -p1
 %patch3 -p1
 %patch4 -p0
+%patch5 -p0
 echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> kernel/Makefile.kbuild
 
 %build
 echo 'EXTRA_CFLAGS += -Wno-pointer-arith -Wno-sign-compare -Wno-unused' >> kernel/Makefile.kbuild
 
 %build
This page took 0.098409 seconds and 4 git commands to generate.