summaryrefslogtreecommitdiffstats
path: root/kernel/fglrx_kernel_3.4.0.patch
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/fglrx_kernel_3.4.0.patch')
-rw-r--r--kernel/fglrx_kernel_3.4.0.patch37
1 files changed, 37 insertions, 0 deletions
diff --git a/kernel/fglrx_kernel_3.4.0.patch b/kernel/fglrx_kernel_3.4.0.patch
new file mode 100644
index 000000000..a3adea286
--- /dev/null
+++ b/kernel/fglrx_kernel_3.4.0.patch
@@ -0,0 +1,37 @@
+--- common/lib/modules/fglrx/build_mod/firegl_public.c
++++ common/lib/modules/fglrx/build_mod/firegl_public.c
+@@ -187,6 +187,9 @@
+ #include <linux/gfp.h>
+ #include <linux/swap.h>
+ #include "asm/i387.h"
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,4,0)
++#include <asm/fpu-internal.h>
++#endif
+
+ #include "firegl_public.h"
+ #include "kcl_osconfig.h"
+@@ -4181,7 +4184,11 @@ static int kasInitExecutionLevels(unsigned long level_init)
+ {
+ unsigned int p;
+ KCL_DEBUG5(FN_FIREGL_KAS, "%d\n", level_init);
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,4,0)
++ for_each_possible_cpu(p)
++#else
+ for_each_cpu_mask(p, cpu_possible_map)
++#endif
+ {
+ KCL_DEBUG1(FN_FIREGL_KAS,"Setting initial execution level for CPU # %d\n", p);
+ preempt_disable();
+--- common/lib/modules/fglrx/build_mod/kcl_ioctl.c
++++ common/lib/modules/fglrx/build_mod/kcl_ioctl.c
+@@ -217,6 +217,10 @@
+ * \param size [in] Number of bytes to allocate
+ * \return Pointer to allocated memory
+ */
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,4,0)
++DEFINE_PER_CPU(unsigned long, old_rsp);
++#endif
++
+ void* ATI_API_CALL KCL_IOCTL_AllocUserSpace32(long size)
+ {
+ void __user *ret = COMPAT_ALLOC_USER_SPACE(size);