rpms/nvidia-173xx-kmod/F-20 nvidia_4.0.0_kernel.patch, NONE, 1.1 nvidia-173xx-kmod.spec, 1.125, 1.126

Leigh Scott leigh123linux at rpmfusion.org
Mon May 25 15:29:07 CEST 2015


Author: leigh123linux

Update of /cvs/nonfree/rpms/nvidia-173xx-kmod/F-20
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv27450

Modified Files:
	nvidia-173xx-kmod.spec 
Added Files:
	nvidia_4.0.0_kernel.patch 
Log Message:
* Mon May 25 2015 Leigh Scott <leigh123linux at googlemail.com> - 173.14.39-6
- Patch for 4.0.0 kernel


nvidia_4.0.0_kernel.patch:
 nv.c |    9 +++++++++
 1 file changed, 9 insertions(+)

--- NEW FILE nvidia_4.0.0_kernel.patch ---
--- a/usr/src/nv/nv.c	2013-11-27 23:16:46.000000000 +0000
+++ b/usr/src/nv/nv.c	2015-05-25 14:26:21.282671891 +0100
@@ -841,8 +841,13 @@ static inline void __nv_disable_caches(u
     unsigned long cr0 = read_cr0();
     write_cr0(((cr0 & (0xdfffffff)) | 0x40000000));
     wbinvd();
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,20,0)
+    *cr4 = __read_cr4();
+    if (*cr4 & 0x80) __write_cr4(*cr4 & ~0x80);
+#else
     *cr4 = read_cr4();
     if (*cr4 & 0x80) write_cr4(*cr4 & ~0x80);
+#endif
     __flush_tlb();
 }
 
@@ -852,7 +857,11 @@ static inline void __nv_enable_caches(un
     wbinvd();
     __flush_tlb();
     write_cr0((cr0 & 0x9fffffff));
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,20,0)
+    if (cr4 & 0x80) __write_cr4(cr4);
+#else
     if (cr4 & 0x80) write_cr4(cr4);
+#endif
 }
 
 static int __determine_pat_mode()


Index: nvidia-173xx-kmod.spec
===================================================================
RCS file: /cvs/nonfree/rpms/nvidia-173xx-kmod/F-20/nvidia-173xx-kmod.spec,v
retrieving revision 1.125
retrieving revision 1.126
diff -u -r1.125 -r1.126
--- nvidia-173xx-kmod.spec	24 May 2015 15:57:49 -0000	1.125
+++ nvidia-173xx-kmod.spec	25 May 2015 13:29:07 -0000	1.126
@@ -3,12 +3,12 @@
 # "buildforkernels newest" macro for just that build; immediately after
 # queuing that build enable the macro again for subsequent builds; that way
 # a new akmod package will only get build when a new one is actually needed
-%global buildforkernels newest
+%global buildforkernels current
 
 Name:          nvidia-173xx-kmod
 Version:       173.14.39
 # Taken over by kmodtool
-Release:       5%{?dist}.6
+Release:       6%{?dist}
 Summary:       NVIDIA 173xx display driver kernel module
 Group:         System Environment/Kernel
 License:       Redistributable, no modification permitted
@@ -20,6 +20,7 @@
 Source0:       nvidia-kmod-data-%{version}.tar.bz2
 Patch0:        nvidia_3.17_kernel.patch
 Patch1:        nvidia_3.19_kernel.patch
+Patch2:        nvidia_4.0.0_kernel.patch
 
 BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
@@ -49,6 +50,7 @@
     pushd nvidiapkg-${arch}
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
     popd
 done
 
@@ -92,6 +94,9 @@
 
 
 %changelog
+* Mon May 25 2015 Leigh Scott <leigh123linux at googlemail.com> - 173.14.39-6
+- Patch for 4.0.0 kernel
+
 * Sun May 24 2015 Nicolas Chauvet <kwizart at gmail.com> - 173.14.39-5.6
 - Rebuilt for kernel
 


More information about the rpmfusion-commits mailing list