[packages/xorg-driver-video-fglrx] - fix building with linux 4.5
baggins
baggins at pld-linux.org
Tue Apr 26 18:26:20 CEST 2016
commit 7b2a186e24d008a7c55b5f8296c01c270fad4dae
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Tue Apr 26 18:26:06 2016 +0200
- fix building with linux 4.5
linux-4.5.patch | 25 +++++++++++++++++++++++++
xorg-driver-video-fglrx.spec | 2 ++
2 files changed, 27 insertions(+)
---
diff --git a/xorg-driver-video-fglrx.spec b/xorg-driver-video-fglrx.spec
index 65eb7a8..47f91dc 100644
--- a/xorg-driver-video-fglrx.spec
+++ b/xorg-driver-video-fglrx.spec
@@ -65,6 +65,7 @@ Patch8: linux-4.0.patch
Patch9: linux-4.2.patch
Patch10: linux-4.3.patch
Patch11: linux-4.4.patch
+Patch12: linux-4.5.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
@@ -234,6 +235,7 @@ EOF
%patch9 -p1
%patch10 -p1
%patch11 -p1
+%patch12 -p1
install -d common{%{_prefix}/{%{_lib},bin,sbin},/etc}
cp -a %{x11ver}%{arch_sufix}/usr/X11R6/%{_lib}/* common%{_libdir}
diff --git a/linux-4.5.patch b/linux-4.5.patch
new file mode 100644
index 0000000..11bb512
--- /dev/null
+++ b/linux-4.5.patch
@@ -0,0 +1,25 @@
+--- xorg-driver-video-radeon-crimson-15.12/common/lib/modules/fglrx/build_mod/firegl_public.c.b 2016-03-30 21:53:04.123817514 +0200
++++ xorg-driver-video-radeon-crimson-15.12/common/lib/modules/fglrx/build_mod/firegl_public.c 2016-03-30 21:54:42.922113915 +0200
+@@ -6467,6 +6437,14 @@ static void _copy_xregs_to_kernel(struct
+ u64 mask = -1;
+ u32 lmask = mask;
+ u32 hmask = mask >> 32;
++
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,5,0)
++ int err;
++
++ /*WARN_ON(!alternatives_patched);*/
++
++ XSTATE_XSAVE(xstate, lmask, hmask, err);
++#else
+ int err = 0;
+
+ /*WARN_ON(!alternatives_patched);*/
+@@ -6494,6 +6472,7 @@ static void _copy_xregs_to_kernel(struct
+ xstate_fault(err)
+ : "0" (err)
+ : "memory");
++#endif
+
+ /* We should never fault when copying to a kernel buffer: */
+ WARN_ON_FPU(err);
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/xorg-driver-video-fglrx.git/commitdiff/7b2a186e24d008a7c55b5f8296c01c270fad4dae
More information about the pld-cvs-commit
mailing list