]> git.pld-linux.org Git - packages/xorg-driver-video-fglrx.git/commitdiff
- fix building with linux 4.0 auto/th/xorg-driver-video-fglrx-14.12-5
authorJan Rękorajski <baggins@pld-linux.org>
Sun, 19 Apr 2015 11:42:18 +0000 (13:42 +0200)
committerJan Rękorajski <baggins@pld-linux.org>
Sun, 19 Apr 2015 11:42:18 +0000 (13:42 +0200)
- rel 5

linux-4.0.patch [new file with mode: 0644]
xorg-driver-video-fglrx.spec

diff --git a/linux-4.0.patch b/linux-4.0.patch
new file mode 100644 (file)
index 0000000..f645595
--- /dev/null
@@ -0,0 +1,71 @@
+diff -ur xorg-driver-video-fglrx-14.12.orig/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/firegl_public.c xorg-driver-video-fglrx-14.12/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/firegl_public.c
+--- xorg-driver-video-fglrx-14.12.orig/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/firegl_public.c    2015-04-19 13:36:55.029786519 +0200
++++ xorg-driver-video-fglrx-14.12/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-04-19 13:40:08.266446369 +0200
+@@ -4468,8 +4468,13 @@
+     if (cpu_has_pge)
+     {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0)
++        cr4 = __read_cr4();
++        __write_cr4(cr4 & ~X86_CR4_PGE);
++#else
+         cr4 = read_cr4();
+         write_cr4(cr4 & ~X86_CR4_PGE);
++#endif
+     }
+      __flush_tlb();
+@@ -4482,7 +4487,11 @@
+     write_cr0(cr0 & 0xbfffffff);
+     if (cpu_has_pge)
+     {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0)
++        __write_cr4(cr4);
++#else
+         write_cr4(cr4);
++#endif
+     }
+     local_irq_restore(flags);
+@@ -4509,8 +4518,13 @@
+     if (cpu_has_pge)
+     {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0)
++        cr4 = __read_cr4();
++        __write_cr4(cr4 & ~X86_CR4_PGE);
++#else
+         cr4 = read_cr4();
+         write_cr4(cr4 & ~X86_CR4_PGE);
++#endif
+     }
+      __flush_tlb();
+   
+@@ -4522,7 +4536,11 @@
+     write_cr0(cr0 & 0xbfffffff);
+     if (cpu_has_pge)
+     {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0)
++        __write_cr4(cr4);
++#else
+         write_cr4(cr4);
++#endif
+     }
+     local_irq_restore(flags);
+Only in xorg-driver-video-fglrx-14.12/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod: firegl_public.c~
+diff -ur xorg-driver-video-fglrx-14.12.orig/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/kcl_str.c xorg-driver-video-fglrx-14.12/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/kcl_str.c
+--- xorg-driver-video-fglrx-14.12.orig/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/kcl_str.c  2014-11-28 21:02:10.000000000 +0100
++++ xorg-driver-video-fglrx-14.12/fglrx-14.501.1003/common/lib/modules/fglrx/build_mod/kcl_str.c       2015-04-19 13:40:41.303111870 +0200
+@@ -169,7 +169,11 @@
+                                   const char* s2,
+                                   KCL_TYPE_SizeSigned count)
+ {
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,0,0)
++    return strncasecmp(s1, s2, count);
++#else
+     return strnicmp(s1, s2, count);
++#endif
+ }
+ /** \brief Locate character in string
index 4f6913c21a85d04ddcad7c29e73f06f2f53057e5..8ad2f869b529b715c72af4881f5a171d58fa9f50 100644 (file)
@@ -31,7 +31,7 @@ exit 1
 %define                betaver         1.0
 #define                rel             0.beta%{betaver}.3
 
-%define                rel             4
+%define                rel             5
 %define                pname           xorg-driver-video-fglrx
 Summary:       Linux Drivers for AMD/ATI graphics accelerators
 Summary(pl.UTF-8):     Sterowniki do akceleratorów graficznych AMD/ATI
@@ -61,6 +61,7 @@ Patch5:               %{pname}-GPL-only.patch
 Patch6:                %{pname}-intel_iommu.patch
 Patch7:                linux-3.17.patch
 Patch8:                linux-3.19.patch
+Patch9:                linux-4.0.patch
 URL:           http://ati.amd.com/support/drivers/linux/linux-radeon.html
 %{?with_kernel:%{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6.20.2}}
 BuildRequires: rpmbuild(macros) >= 1.701
@@ -232,6 +233,7 @@ EOF
 %patch6 -p1
 %patch7 -p1
 %patch8 -p1
+%patch9 -p2
 
 install -d common{%{_prefix}/{%{_lib},bin,sbin},/etc}
 cp -a %{x11ver}%{arch_sufix}/usr/X11R6/%{_lib}/* common%{_libdir}
This page took 0.070511 seconds and 4 git commands to generate.