summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorVi0L02017-03-04 18:25:30 +0100
committerVi0L02017-03-04 18:25:30 +0100
commit16054c863bad21d46847062c39d806789936784f (patch)
tree08ed9cbcf8edb4842f61aa69f86d4c99d4279855
parent5ae828b9b74fb4a055d9dc3950cbcfc99e83db87 (diff)
downloadaur-16054c863bad21d46847062c39d806789936784f.tar.gz
13.1-40: experimental 4.9 and 4.10 kernels support
-rw-r--r--.SRCINFO17
-rw-r--r--4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch91
-rw-r--r--4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch13
-rw-r--r--PKGBUILD25
4 files changed, 134 insertions, 12 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 70b8de8c9e3..4f38f3c91e9 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = catalyst-total-hd234k
pkgdesc = AMD/ATI legacy drivers. catalyst-dkms+ catalyst-utils + lib32-catalyst-utils
pkgver = 13.1
- pkgrel = 39
+ pkgrel = 40
url = http://www.amd.com
install = catalyst-total-hd234k.install
arch = i686
@@ -9,7 +9,7 @@ pkgbase = catalyst-total-hd234k
license = custom
depends = dkms
depends = linux>=3.0
- depends = linux<4.9
+ depends = linux<4.11
depends = linux-headers
depends = xorg-server>=1.7.0
depends = xorg-server<1.13.0
@@ -23,7 +23,7 @@ pkgbase = catalyst-total-hd234k
depends = make
depends = patch
depends = libxinerama
- depends = mesa>=10.1.0-4
+ depends = mesa
optdepends = qt4: to run ATi Catalyst Control Center (amdcccle)
optdepends = libxxf86vm: to run ATi Catalyst Control Center (amdcccle)
optdepends = opencl-headers: headers necessary for OpenCL development
@@ -40,6 +40,8 @@ pkgbase = catalyst-total-hd234k
provides = dri
provides = libtxc_dxtn
provides = opencl-driver
+ provides = libgles
+ provides = libegl
conflicts = libgl
conflicts = xf86-video-ati
conflicts = xf86-video-radeonhd
@@ -51,6 +53,11 @@ pkgbase = catalyst-total-hd234k
conflicts = catalyst-generator
conflicts = catalyst-dkms
conflicts = catalyst-utils
+ conflicts = mesa-libgl
+ conflicts = mesa-libgl-git
+ conflicts = libgles
+ conflicts = libegl
+ conflicts = opencl-amd
options = staticlibs
options = libtool
options = !strip
@@ -88,6 +95,8 @@ pkgbase = catalyst-total-hd234k
source = makesh-dont-check-gcc-version.patch
source = makesh-src_file.patch
source = 4.7-cpu_has_pge-hd234k.patch
+ source = 4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch
+ source = 4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch
md5sums = c07fd1332abe4c742a9a0d0e0d0a90de
md5sums = af7fb8ee4fc96fd54c5b483e33dc71c4
md5sums = bdafe749e046bfddee2d1c5e90eabd83
@@ -121,6 +130,8 @@ pkgbase = catalyst-total-hd234k
md5sums = 10829e3b992b3e80a6e78c8e27748703
md5sums = 6cdc15206cc61e3de456416a9011db07
md5sums = 1e56499f8589d81a1a5eba98bad9912c
+ md5sums = 29f82a5a60a1c28411e0d4b67f26fbf9
+ md5sums = 7b18613d2872192fb5afee699bb1f8fe
pkgname = catalyst-total-hd234k
diff --git a/4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch b/4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch
new file mode 100644
index 00000000000..9b0b08d407d
--- /dev/null
+++ b/4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch
@@ -0,0 +1,91 @@
+diff -uNr 17.2/common/lib/modules/fglrx/build_mod/firegl_public.c 17.2b/common/lib/modules/fglrx/build_mod/firegl_public.c
+--- 17.2/common/lib/modules/fglrx/build_mod/firegl_public.c 2017-02-12 19:41:19.000000000 +0100
++++ 17.2b/common/lib/modules/fglrx/build_mod/firegl_public.c 2017-02-12 20:27:36.924630194 +0100
+@@ -3225,7 +3225,9 @@
+ int ret;
+
+ down_read(&current->mm->mmap_sem);
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,9,0)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ ret = get_user_pages_remote(current, current->mm, vaddr, page_cnt, 1, (struct page **)page_list, NULL, NULL);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4,9,0)
+ ret = get_user_pages_remote(current, current->mm, vaddr, page_cnt, 1, (struct page **)page_list, NULL);
+ #elif LINUX_VERSION_CODE >= KERNEL_VERSION(4,6,0)
+ ret = get_user_pages_remote(current, current->mm, vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL);
+@@ -3626,7 +3630,9 @@
+ unsigned long vma_offset;
+ unsigned long pte_linear;
+ mem_map_t* pMmPage;
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ unsigned long address = (unsigned long) (vmf->address);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+ unsigned long address = (unsigned long) (vmf->virtual_address);
+ #endif
+
+@@ -3701,7 +3707,9 @@
+ {
+ unsigned long kaddr;
+ mem_map_t* pMmPage;
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ unsigned long address = (unsigned long) (vmf->address);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+ unsigned long address = (unsigned long) (vmf->virtual_address);
+ #endif
+
+@@ -3746,7 +3754,9 @@
+ {
+ unsigned long kaddr;
+ mem_map_t* pMmPage;
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ unsigned long address = (unsigned long) (vmf->address);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+ unsigned long address = (unsigned long) (vmf->virtual_address);
+ #endif
+
+@@ -3809,7 +3819,9 @@
+ mem_map_t* pMmPage;
+ struct firegl_pcie_mem* pciemem;
+ unsigned long* pagelist;
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ unsigned long address = (unsigned long) (vmf->address);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+ unsigned long address = (unsigned long) (vmf->virtual_address);
+ #endif
+
+@@ -3871,7 +3883,9 @@
+
+ unsigned long offset;
+ struct page *page;
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++ unsigned long address = (unsigned long) (vmf->address);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,26)
+ unsigned long address = (unsigned long) (vmf->virtual_address);
+ #endif
+
+@@ -4166,12 +4180,21 @@
+
+ #else
+
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)
++#define TRACE_FAULT(_f, _v,_a) \
++ int ret; \
++ KCL_DEBUG_TRACEIN(FN_DRM_NOPAGE, (unsigned long)_a->address, NULL); \
++ ret = _f(_v,_a); \
++ KCL_DEBUG_TRACEOUT(FN_DRM_NOPAGE, ret, NULL); \
++ return ret;
++#else
+ #define TRACE_FAULT(_f, _v,_a) \
+ int ret; \
+ KCL_DEBUG_TRACEIN(FN_DRM_NOPAGE, (unsigned long)_a->virtual_address, NULL); \
+ ret = _f(_v,_a); \
+ KCL_DEBUG_TRACEOUT(FN_DRM_NOPAGE, ret, NULL); \
+ return ret;
++#endif
+
+ static int ip_vm_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
+ {
diff --git a/4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch b/4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch
new file mode 100644
index 00000000000..7247ead2405
--- /dev/null
+++ b/4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch
@@ -0,0 +1,13 @@
+--- 16.12/common/lib/modules/fglrx/build_mod/firegl_public.c 2016-12-10 19:44:46.764677311 +0100
++++ 16.12b/common/lib/modules/fglrx/build_mod/firegl_public.c 2016-12-10 19:45:43.941354338 +0100
+@@ -3225,7 +3225,9 @@
+ int ret;
+
+ down_read(&current->mm->mmap_sem);
+-#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,6,0)
++#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,9,0)
++ ret = get_user_pages_remote(current, current->mm, vaddr, page_cnt, 1, (struct page **)page_list, NULL);
++#elif LINUX_VERSION_CODE >= KERNEL_VERSION(4,6,0)
+ ret = get_user_pages_remote(current, current->mm, vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL);
+ #else
+ ret = get_user_pages(current, current->mm, vaddr, page_cnt, 1, 0, (struct page **)page_list, NULL);
diff --git a/PKGBUILD b/PKGBUILD
index 80e718ef42b..64e269751ec 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -22,35 +22,36 @@
# Contributor: gentoo (patch for 3.10 + part of 4.3 kernel patches)
# Contributor: aslmaswd (acpi main script)
# Contributor: npfeiler (libcl/opencl-icd-loader cleaning)
+# Contributor: sling00 (4.10 kernel patch)
pkgname=catalyst-total-hd234k
pkgver=13.1
-pkgrel=39
+pkgrel=40
pkgdesc="AMD/ATI legacy drivers. catalyst-dkms+ catalyst-utils + lib32-catalyst-utils"
arch=('i686' 'x86_64')
url="http://www.amd.com"
license=('custom')
options=('staticlibs' 'libtool' '!strip' '!upx')
-depends=('dkms' 'linux>=3.0' 'linux<4.9' 'linux-headers' 'xorg-server>=1.7.0' 'xorg-server<1.13.0' 'libxrandr' 'libsm' 'fontconfig' 'libxcursor' 'libxi' 'gcc-libs' 'gcc>4.0.0' 'make' 'patch' 'libxinerama' 'mesa>=10.1.0-4')
+depends=('dkms' 'linux>=3.0' 'linux<4.11' 'linux-headers' 'xorg-server>=1.7.0' 'xorg-server<1.13.0' 'libxrandr' 'libsm' 'fontconfig' 'libxcursor' 'libxi' 'gcc-libs' 'gcc>4.0.0' 'make' 'patch' 'libxinerama' 'mesa')
optdepends=('qt4: to run ATi Catalyst Control Center (amdcccle)'
'libxxf86vm: to run ATi Catalyst Control Center (amdcccle)'
'opencl-headers: headers necessary for OpenCL development'
'acpid: acpi event support / atieventsd'
'linux-lts-headers: to build the fglrx module for the linux-lts kernel'
'opencl-icd-loader: OpenCL ICD Bindings')
-conflicts=('libgl' 'xf86-video-ati' 'xf86-video-radeonhd' 'catalyst-test' 'nvidia-utils' 'nvidia' 'catalyst' 'catalyst-daemon' 'catalyst-generator' 'catalyst-dkms' 'catalyst-utils')
-provides=('libgl' "libatical=${pkgver}" "catalyst=${pkgver}" "catalyst-utils=${pkgver}" "catalyst-dkms=${pkgver}" "catalyst-libgl=${pkgver}" "opencl-catalyst=${pkgver}" 'dri' 'libtxc_dxtn' 'opencl-driver')
+conflicts=('libgl' 'xf86-video-ati' 'xf86-video-radeonhd' 'catalyst-test' 'nvidia-utils' 'nvidia' 'catalyst' 'catalyst-daemon' 'catalyst-generator' 'catalyst-dkms' 'catalyst-utils' 'mesa-libgl' 'mesa-libgl-git' 'libgles' 'libegl' 'opencl-amd')
+provides=('libgl' "libatical=${pkgver}" "catalyst=${pkgver}" "catalyst-utils=${pkgver}" "catalyst-dkms=${pkgver}" "catalyst-libgl=${pkgver}" "opencl-catalyst=${pkgver}" 'dri' 'libtxc_dxtn' 'opencl-driver' 'libgles' 'libegl')
if [ "${CARCH}" = "x86_64" ]; then
warning "x86_64 system detected"
warning "[multilib] repository must be uncommented in /etc/pacman.conf to add lib32-catalyst-utils into the package"
if [[ `cat /etc/pacman.conf | grep -c "#\[multilib]"` = 0 ]]; then
warning "OK, lib32-catalyst-utils will be added to the package"
- depends+=('lib32-libxext' 'lib32-libdrm' 'lib32-libxinerama' 'lib32-mesa>=10.1.0-4')
- conflicts+=('lib32-libgl' 'lib32-nvidia-utils' 'lib32-catalyst-utils')
- provides+=('lib32-libgl' "lib32-catalyst-utils=${pkgver}" "lib32-catalyst-libgl=${pkgver}" "lib32-opencl-catalyst=${pkgver}" 'lib32-dri' 'lib32-libtxc_dxtn' 'lib32-opencl-driver')
+ depends+=('lib32-libxext' 'lib32-libdrm' 'lib32-libxinerama' 'lib32-mesa')
+ conflicts+=('lib32-libgl' 'lib32-nvidia-utils' 'lib32-catalyst-utils' 'lib32-libgles' 'lib32-libegl')
+ provides+=('lib32-libgl' "lib32-catalyst-utils=${pkgver}" "lib32-catalyst-libgl=${pkgver}" "lib32-opencl-catalyst=${pkgver}" 'lib32-dri' 'lib32-libtxc_dxtn' 'lib32-opencl-driver' 'lib32-libgles' 'lib32-libegl')
optdepends+=('lib32-opencl-icd-loader: OpenCL ICD Bindings (32-bit)')
else
warning "lib32-catalyst-utils will NOT be added to the package"
@@ -101,7 +102,9 @@ source=(
makesh-dont-check-gcc-version.patch
makesh-src_file.patch
- 4.7-cpu_has_pge-hd234k.patch)
+ 4.7-cpu_has_pge-hd234k.patch
+ 4.9_over_4.6-arch-get_user_pages_remote-hd234k.patch
+ 4.10-arch-sling00-virtual_address-acpi_get_table_with_size-hd234k.patch)
md5sums=('c07fd1332abe4c742a9a0d0e0d0a90de'
'af7fb8ee4fc96fd54c5b483e33dc71c4'
@@ -141,7 +144,9 @@ md5sums=('c07fd1332abe4c742a9a0d0e0d0a90de'
'10829e3b992b3e80a6e78c8e27748703'
'6cdc15206cc61e3de456416a9011db07'
- '1e56499f8589d81a1a5eba98bad9912c')
+ '1e56499f8589d81a1a5eba98bad9912c'
+ '29f82a5a60a1c28411e0d4b67f26fbf9'
+ '7b18613d2872192fb5afee699bb1f8fe')
build() {
@@ -323,6 +328,8 @@ package() {
patch -Np1 -i ../makesh-dont-check-gcc-version.patch
patch -Np1 -i ../makesh-src_file.patch
patch -Np1 -i ../4.7-cpu_has_pge-hd234k.patch
+ patch -Np1 -i ../4.9_over_4.6-arch-get_user_pages_remote.patch
+ patch -Np1 -i ../4.10-arch-sling00-virtual_address-acpi_get_table_with_size.patch
# Prepare modules source files