diff options
Diffstat (limited to 'pkgs/os-specific/linux/ati-drivers/patches')
10 files changed, 0 insertions, 346 deletions
diff --git a/pkgs/os-specific/linux/ati-drivers/patches/15.12-xstate-fp.patch b/pkgs/os-specific/linux/ati-drivers/patches/15.12-xstate-fp.patch deleted file mode 100644 index 22e43fc0c7b..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/15.12-xstate-fp.patch +++ /dev/null @@ -1,26 +0,0 @@ -From: Krzysztof Kolasa <kkolasa@winsoft.pl> -Date: Thu, 26 Nov 2015 14:28:46 +0100 -Subject: [PATCH] Patch for kernel 4.4.0-rc2 - -constant change of name XSTATE_XP to name XFEATURE_MASK_FP ---- - firegl_public.c | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c -index 3626c7b..f071d42 100644 ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c -+++ b/common/lib/modules/fglrx/build_mod//firegl_public.c -@@ -6463,7 +6463,11 @@ static int KCL_fpu_save_init(struct task_struct *tsk) - if (!(fpu->state->xsave.xsave_hdr.xstate_bv & XSTATE_FP)) - #else - copy_xregs_to_kernel(&fpu->state.xsave); -- if (!(fpu->state.xsave.header.xfeatures & XSTATE_FP)) -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,4,0) -+ if (!(fpu->state.xsave.header.xfeatures & XFEATURE_MASK_FP)) -+#else -+ if (!(fpu->state.xsave.header.xfeatures & XSTATE_FP)) -+#endif - #endif - return 1; - } else if (static_cpu_has(X86_FEATURE_FXSR)) { diff --git a/pkgs/os-specific/linux/ati-drivers/patches/15.9-kcl_str.patch b/pkgs/os-specific/linux/ati-drivers/patches/15.9-kcl_str.patch deleted file mode 100644 index 20c3bc8a169..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/15.9-kcl_str.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- a/common/lib/modules/fglrx/build_mod/kcl_str.c 2015-09-13 13:47:30.000000000 -0400 -+++ b/common/lib/modules/fglrx/build_mod/kcl_str.c 2015-09-13 13:49:42.000000000 -0400 -@@ -169,7 +169,11 @@ int ATI_API_CALL KCL_STR_Strnicmp(const - const char* s2, - KCL_TYPE_SizeSigned count) - { -+#if LINUX_VERSION_CODE < KERNEL_VERSION(4,0,0) - return strnicmp(s1, s2, count); -+#else -+ return strncasecmp(s1, s2, count); -+#endif - } - - /** \brief Locate character in string diff --git a/pkgs/os-specific/linux/ati-drivers/patches/15.9-mtrr.patch b/pkgs/os-specific/linux/ati-drivers/patches/15.9-mtrr.patch deleted file mode 100644 index bdf70b4ccdc..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/15.9-mtrr.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-09-19 23:43:22.000000000 -0400 -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-09-19 23:52:07.000000000 -0400 -@@ -3442,7 +3442,11 @@ int ATI_API_CALL KCL_MEM_MTRR_Support(vo - int ATI_API_CALL KCL_MEM_MTRR_AddRegionWc(unsigned long base, unsigned long size) - { - #ifdef CONFIG_MTRR -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0) -+ return arch_phys_wc_add(base, size); -+#else - return mtrr_add(base, size, MTRR_TYPE_WRCOMB, 1); -+#endif - #else /* !CONFIG_MTRR */ - return -EPERM; - #endif /* !CONFIG_MTRR */ -@@ -3451,7 +3455,12 @@ int ATI_API_CALL KCL_MEM_MTRR_AddRegionW - int ATI_API_CALL KCL_MEM_MTRR_DeleteRegion(int reg, unsigned long base, unsigned long size) - { - #ifdef CONFIG_MTRR -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0) -+ arch_phys_wc_del(reg); -+ return reg; -+#else - return mtrr_del(reg, base, size); -+#endif - #else /* !CONFIG_MTRR */ - return -EPERM; - #endif /* !CONFIG_MTRR */ diff --git a/pkgs/os-specific/linux/ati-drivers/patches/15.9-preempt.patch b/pkgs/os-specific/linux/ati-drivers/patches/15.9-preempt.patch deleted file mode 100644 index c6598835133..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/15.9-preempt.patch +++ /dev/null @@ -1,103 +0,0 @@ ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-08-30 17:36:02.000000000 -0400 -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-08-30 17:39:36.000000000 -0400 -@@ -21,6 +21,8 @@ - !!! since it requires changes to linux/init/main.c. - #endif /* !MODULE */ - -+#include <linux/preempt.h> -+ - // ============================================================ - #include <linux/version.h> - -@@ -4997,7 +4999,9 @@ static unsigned int kas_spin_unlock(kas_ - unsigned long ATI_API_CALL KAS_GetExecutionLevel(void) - { - unsigned long ret; -+ preempt_disable(); - ret = kas_GetExecutionLevel(); -+ preempt_enable(); - return ret; - } - -@@ -5022,8 +5026,10 @@ unsigned int ATI_API_CALL KAS_Ih_Execute - KCL_DEBUG5(FN_FIREGL_KAS,"0x%08X, 0x%08X\n", ih_routine, ih_context); - - //Prevent simultaneous entry on some SMP systems. -+ preempt_disable(); - if (test_and_set_bit(0, (void *)&(kasContext.in_interrupts[smp_processor_id()]))) - { -+ preempt_enable(); - KCL_DEBUG1(FN_FIREGL_KAS, "The processor is handling the interrupt\n"); - return IRQ_NONE; - } -@@ -5036,9 +5042,9 @@ unsigned int ATI_API_CALL KAS_Ih_Execute - - kasSetExecutionLevel(orig_level); - spin_unlock(&kasContext.lock_ih); -- - clear_bit(0, (void *)&(kasContext.in_interrupts[smp_processor_id()])); - KCL_DEBUG5(FN_FIREGL_KAS,"%d\n", ret); -+ preempt_enable(); - - return ret; - } -@@ -5256,6 +5262,7 @@ unsigned int ATI_API_CALL KAS_Spinlock_A - - KCL_DEBUG5(FN_FIREGL_KAS,"0x%08X\n", hSpinLock); - -+ preempt_disable(); - spin_lock_info.routine_type = spinlock_obj->routine_type; - spin_lock_info.plock = &(spinlock_obj->lock); - -@@ -5263,6 +5270,7 @@ unsigned int ATI_API_CALL KAS_Spinlock_A - - spinlock_obj->acquire_type = spin_lock_info.acquire_type; - spinlock_obj->flags = spin_lock_info.flags; -+ preempt_enable(); - - KCL_DEBUG5(FN_FIREGL_KAS,"%d\n", ret); - return ret; -@@ -6034,6 +6042,8 @@ unsigned int ATI_API_CALL KAS_Interlocke - - KCL_DEBUG5(FN_FIREGL_KAS,"0x%08X, 0x%08X, 0x%08X\n", hListHead, hListEntry, phPrevEntry); - -+ preempt_disable(); -+ - /* Protect the operation with spinlock */ - spin_lock_info.routine_type = listhead_obj->routine_type; - spin_lock_info.plock = &(listhead_obj->lock); -@@ -6041,6 +6051,7 @@ unsigned int ATI_API_CALL KAS_Interlocke - if (!kas_spin_lock(&spin_lock_info)) - { - KCL_DEBUG_ERROR("Unable to grab list spinlock\n"); -+ preempt_enable(); - return 0; /* No spinlock - no operation */ - } - -@@ -6065,6 +6076,7 @@ unsigned int ATI_API_CALL KAS_Interlocke - spin_unlock_info.flags = spin_lock_info.flags; - - ret = kas_spin_unlock(&spin_unlock_info); -+ preempt_enable(); - KCL_DEBUG5(FN_FIREGL_KAS,"%d", ret); - return ret; - } -@@ -6153,8 +6165,10 @@ unsigned int ATI_API_CALL KAS_Interlocke - spin_lock_info.routine_type = listhead_obj->routine_type; - spin_lock_info.plock = &(listhead_obj->lock); - -+ preempt_disable(); - if (!kas_spin_lock(&spin_lock_info)) - { -+ preempt_enable(); - KCL_DEBUG_ERROR("Unable to grab list spinlock"); - return 0; /* No spinlock - no operation */ - } -@@ -6178,6 +6192,7 @@ unsigned int ATI_API_CALL KAS_Interlocke - spin_unlock_info.flags = spin_lock_info.flags; - - ret = kas_spin_unlock(&spin_unlock_info); -+ preempt_enable(); - KCL_DEBUG5(FN_FIREGL_KAS,"%d", ret); - return ret; - } diff --git a/pkgs/os-specific/linux/ati-drivers/patches/15.9-sep_printf.patch b/pkgs/os-specific/linux/ati-drivers/patches/15.9-sep_printf.patch deleted file mode 100644 index 3e4e8d6499a..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/15.9-sep_printf.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-09-14 15:14:36.000000000 -0400 -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-09-14 16:18:58.000000000 -0400 -@@ -649,6 +649,8 @@ static int firegl_major_proc_read(struct - *eof = 1; - - len = snprintf(buf, request, "%d\n", major); -+#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0) -+ seq_printf(m, "%d\n", major); - #else - len = seq_printf(m, "%d\n", major); - #endif diff --git a/pkgs/os-specific/linux/ati-drivers/patches/4.7-arch-cpu_has_pge-v2.patch b/pkgs/os-specific/linux/ati-drivers/patches/4.7-arch-cpu_has_pge-v2.patch deleted file mode 100644 index cb86f5aff27..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/4.7-arch-cpu_has_pge-v2.patch +++ /dev/null @@ -1,70 +0,0 @@ -diff -uNr 16.8/common/lib/modules/fglrx/build_mod/firegl_public.c 16.8b/common/lib/modules/fglrx/build_mod/firegl_public.c ---- 16.8/common/lib/modules/fglrx/build_mod/firegl_public.c 2015-12-18 19:47:41.000000000 +0100 -+++ 16.8b/common/lib/modules/fglrx/build_mod/firegl_public.c 2016-08-15 15:09:37.228538907 +0200 -@@ -4518,7 +4518,11 @@ - write_cr0(cr0); - wbinvd(); - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,7,0) -+ if (boot_cpu_has(X86_FEATURE_PGE)) -+#else - if (cpu_has_pge) -+#endif - { - cr4 = READ_CR4(); - WRITE_CR4(cr4 & ~X86_CR4_PGE); -@@ -4532,7 +4536,11 @@ - wbinvd(); - __flush_tlb(); - write_cr0(cr0 & 0xbfffffff); -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,7,0) -+ if (boot_cpu_has(X86_FEATURE_PGE)) -+#else - if (cpu_has_pge) -+#endif - { - WRITE_CR4(cr4); - } -@@ -4559,7 +4567,11 @@ - write_cr0(cr0); - wbinvd(); - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,7,0) -+ if (boot_cpu_has(X86_FEATURE_PGE)) -+#else - if (cpu_has_pge) -+#endif - { - cr4 = READ_CR4(); - WRITE_CR4(cr4 & ~X86_CR4_PGE); -@@ -4572,7 +4584,11 @@ - wbinvd(); - __flush_tlb(); - write_cr0(cr0 & 0xbfffffff); -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,7,0) -+ if (boot_cpu_has(X86_FEATURE_PGE)) -+#else - if (cpu_has_pge) -+#endif - { - WRITE_CR4(cr4); - } -diff -uNr 16.8/common/lib/modules/fglrx/build_mod/firegl_public.h 16.8b/common/lib/modules/fglrx/build_mod/firegl_public.h ---- 16.8/common/lib/modules/fglrx/build_mod/firegl_public.h 2015-12-18 19:47:41.000000000 +0100 -+++ 16.8b/common/lib/modules/fglrx/build_mod/firegl_public.h 2016-08-15 15:09:05.815141238 +0200 -@@ -650,9 +650,15 @@ - #define cpu_has_pat test_bit(X86_FEATURE_PAT, (void *) &boot_cpu_data.x86_capability) - #endif - -+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,7,0) -+#ifndef boot_cpu_has(X86_FEATURE_PGE) -+#define boot_cpu_has(X86_FEATURE_PGE) test_bit(X86_FEATURE_PGE, &boot_cpu_data.x86_capability) -+#endif -+#else - #ifndef cpu_has_pge - #define cpu_has_pge test_bit(X86_FEATURE_PGE, &boot_cpu_data.x86_capability) - #endif -+#endif - - /* 2.6.29 defines pgprot_writecombine as a macro which resolves to a - * GPL-only function with the same name. So we always use our own diff --git a/pkgs/os-specific/linux/ati-drivers/patches/4.9-get_user_pages.patch b/pkgs/os-specific/linux/ati-drivers/patches/4.9-get_user_pages.patch deleted file mode 100644 index 8a6c42cdb1f..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/4.9-get_user_pages.patch +++ /dev/null @@ -1,28 +0,0 @@ -commit b3e4353fc68a6a024dcb95e2d61aa0afd7370233 -Author: Matt McHenry <matt@mchenryfamily.org> -Date: Fri Feb 3 20:19:41 2017 - - patch for 4.9 only - -diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c -index 4ce095f..3b591e1 100755 ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c -@@ -3224,7 +3224,7 @@ int ATI_API_CALL KCL_LockUserPages(unsigned long vaddr, unsigned long* page_list - int ret; - - down_read(¤t->mm->mmap_sem); -- ret = get_user_pages(vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL); -+ ret = get_user_pages(vaddr, page_cnt, 1, (struct page **)page_list, NULL); - up_read(¤t->mm->mmap_sem); - - return ret; -@@ -3242,7 +3242,7 @@ int ATI_API_CALL KCL_LockReadOnlyUserPages(unsigned long vaddr, unsigned long* p - int ret; - - down_read(¤t->mm->mmap_sem); -- ret = get_user_pages(vaddr, page_cnt, 0, 0, (struct page **)page_list, NULL); -+ ret = get_user_pages(vaddr, page_cnt, 0, (struct page **)page_list, NULL); - up_read(¤t->mm->mmap_sem); - - return ret; diff --git a/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-get_user_pages.patch b/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-get_user_pages.patch deleted file mode 100644 index 1e7209ed5ed..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-get_user_pages.patch +++ /dev/null @@ -1,25 +0,0 @@ -diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c -index 9c70211..b2242af 100755 ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c -@@ -3220,7 +3220,7 @@ int ATI_API_CALL KCL_LockUserPages(unsigned long vaddr, unsigned long* page_list - int ret; - - down_read(¤t->mm->mmap_sem); -- ret = get_user_pages(current, current->mm, vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL); -+ ret = get_user_pages(vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL); - up_read(¤t->mm->mmap_sem); - - return ret; -@@ -3238,7 +3238,7 @@ int ATI_API_CALL KCL_LockReadOnlyUserPages(unsigned long vaddr, unsigned long* p - int ret; - - down_read(¤t->mm->mmap_sem); -- ret = get_user_pages(current, current->mm, vaddr, page_cnt, 0, 0, (struct page **)page_list, NULL); -+ ret = get_user_pages(vaddr, page_cnt, 0, 0, (struct page **)page_list, NULL); - up_read(¤t->mm->mmap_sem); - - return ret; --- -2.9.2 - diff --git a/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-page_cache_release-put_page.patch b/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-page_cache_release-put_page.patch deleted file mode 100644 index 28820790e49..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/kernel-4.6-page_cache_release-put_page.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c -index b2242af..586129c 100755 ---- a/common/lib/modules/fglrx/build_mod/firegl_public.c -+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c -@@ -3249,7 +3249,7 @@ void ATI_API_CALL KCL_UnlockUserPages(unsigned long* page_list, unsigned int pag - unsigned int i; - for (i=0; i<page_cnt; i++) - { -- page_cache_release((struct page*)page_list[i]); -+ put_page((struct page*)page_list[i]); - } - } - --- -2.9.2 - diff --git a/pkgs/os-specific/linux/ati-drivers/patches/patch-samples.patch b/pkgs/os-specific/linux/ati-drivers/patches/patch-samples.patch deleted file mode 100644 index 8bd24b1d022..00000000000 --- a/pkgs/os-specific/linux/ati-drivers/patches/patch-samples.patch +++ /dev/null @@ -1,26 +0,0 @@ -diff --git a/samples/fgl_glxgears/fgl_glxgears.c b/samples/fgl_glxgears/fgl_glxgears.c -index 6c8e313..2b8d035 100644 ---- a/samples/fgl_glxgears/fgl_glxgears.c -+++ b/samples/fgl_glxgears/fgl_glxgears.c -@@ -1096,8 +1096,6 @@ static void event_loop(void) - view_rotx -= 5.0; - } - else { -- r = XLookupString(&event.xkey, buffer, sizeof(buffer), -- NULL, NULL); - if (buffer[0] == 27) { - /* escape */ - return; - - -diff -Nur a/samples/fgl_glxgears/fgl_glxgears.c b/samples/fgl_glxgears/fgl_glxgears.c ---- a/samples/fgl_glxgears/fgl_glxgears.c 2012-08-29 09:59:03.000000000 +0300 -+++ b/samples/fgl_glxgears/fgl_glxgears.c 2013-09-07 09:26:11.034723135 +0300 -@@ -78,7 +78,6 @@ - #endif // _WIN32 - - #define INT_PTR ptrdiff_t --#include <GL/glATI.h> - - #ifdef _WIN32 - #include <GL/wglATI.h> |