diff options
author | Romain Perier <romain.perier@free-electrons.com> | 2016-08-23 14:19:47 +0200 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2016-08-23 18:00:40 +0200 |
commit | 689ae6e404c8d54a600cb4c62976a9987c08c022 (patch) | |
tree | 87c6b3574fec86ba64f7dec9db577dfc2e4e0a48 /package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch | |
parent | 1091f0978c6808292ad8d088e82c4cd4c118ea99 (diff) | |
download | buildroot-689ae6e404c8d54a600cb4c62976a9987c08c022.tar.gz buildroot-689ae6e404c8d54a600cb4c62976a9987c08c022.zip |
package/amd-catalyst: Add AMD proprietary graphic stack support
This commits adds support for the AMD Catalyst Linux driver 15.9
(15.201.1151). It includes the fglrx kernel module with various fixes
to make it work with at least Linux kernel 4.4 LTS, the userspace OpenGL
stack and the xorg driver module.
Signed-off-by: Romain Perier <romain.perier@free-electrons.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
[Thomas:
- fixup whitespace issues noticed by Yann.
- register AMD_CATALYST_PREPARE_MODULE as a post-patch hook rather than
calling it during the configure step, also suggested by Yann.]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch')
-rw-r--r-- | package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch b/package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch new file mode 100644 index 0000000000..a0db9621a1 --- /dev/null +++ b/package/amd-catalyst/0001-Add-support-for-Linux-4.0.patch @@ -0,0 +1,45 @@ +From c35482bc0cc56b40263b74c3e58e42be867fd9f2 Mon Sep 17 00:00:00 2001 +From: Alberto Milone <alberto.milone@canonical.com> +Date: Thu, 17 Sep 2015 15:41:46 +0200 +Subject: [PATCH] Add support for Linux 4.0 + +Signed-off-by: Romain Perier <romain.perier@free-electrons.com> +--- + common/lib/modules/fglrx/build_mod/firegl_public.c | 5 +++++ + common/lib/modules/fglrx/build_mod/kcl_str.c | 4 ++++ + 2 files changed, 9 insertions(+) + +diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c +index 677565d..6017e89 100755 +--- a/common/lib/modules/fglrx/build_mod/firegl_public.c ++++ b/common/lib/modules/fglrx/build_mod/firegl_public.c +@@ -285,6 +285,11 @@ MODULE_DEVICE_TABLE(pci, fglrx_pci_table); + + MODULE_INFO(supported, "external"); + ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 20, 0) ++#define read_cr4() __read_cr4() ++#define write_cr4(cr4) __write_cr4(cr4) ++#endif ++ + /* globals constants */ + const char* KCL_SYSINFO_OsVersionString = UTS_RELEASE; + const unsigned int KCL_SYSINFO_PageSize = PAGE_SIZE; +diff --git a/common/lib/modules/fglrx/build_mod/kcl_str.c b/common/lib/modules/fglrx/build_mod/kcl_str.c +index 2d89eb0..bacdb69 100755 +--- a/common/lib/modules/fglrx/build_mod/kcl_str.c ++++ b/common/lib/modules/fglrx/build_mod/kcl_str.c +@@ -42,6 +42,10 @@ + #include "kcl_type.h" + #include "kcl_str.h" + ++#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 20, 0) ++#define strnicmp strncasecmp ++#endif ++ + /** \brief Fill memory with a constant byte + * \param s Pointer to memory + * \param c Initializing value +-- +2.8.1 + |