• Skip to sidebar navigation
  • Skip to content

Bitbucket

  • More
    ProjectsRepositories
  • Help
    • Online help
    • Learn Git
    • Welcome to Bitbucket
    • Keyboard shortcuts
  • Log In
Alexander Dahl
  1. Alexander Dahl

buildroot

Public
Actions
  • Clone
  • Compare

Learn more about cloning repositories

You have read-only access

Navigation
  • Source
  • Commits
  • Branches
  • All Branches Graph
  • Forks
  1. Alexander Dahl
  2. buildroot

Source

buildroot/package/amd-catalyst/0006-Add-support-for-Linux-4.4.patch
Romain PerierRomain Perier committed 689ae6e404c23 Aug 2016
Raw file
Source viewDiff to previous
 
1
From 54b230e26a1889c08507e791ab043f8a4b4ff771 Mon Sep 17 00:00:00 2001
2
From: Romain Perier <romain.perier@free-electrons.com>
3
Date: Thu, 7 Jul 2016 14:40:53 +0200
4
Subject: [PATCH] Add support for Linux 4.4
5
​
6
It fixes various things like the use of seq_printf because its API
7
changed. It also replaces the call to mtrr_add and mtrr_del by
8
arch_phys_wc_add and arch_phys_wc_del because these symbols are
9
no longer exported for Linux >= 4.3.x.
10
​
11
Signed-off-by: Romain Perier <romain.perier@free-electrons.com>
12
---
13
 common/lib/modules/fglrx/build_mod/firegl_public.c | 21 +++++++++++++++++++++
14
 1 file changed, 21 insertions(+)
15
​
16
diff --git a/common/lib/modules/fglrx/build_mod/firegl_public.c b/common/lib/modules/fglrx/build_mod/firegl_public.c
17
index bb67bba..b4b2d30 100755
18
--- a/common/lib/modules/fglrx/build_mod/firegl_public.c
19
+++ b/common/lib/modules/fglrx/build_mod/firegl_public.c
20
@@ -636,9 +636,16 @@ static int firegl_major_proc_read(struct seq_file *m, void* data)
21
 
22
     len = snprintf(buf, request, "%d\n", major);
23
 #else
24
+
25
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0)
26
+    seq_printf(m, "%d\n", major);
27
+    len = 0;
28
+#else
29
     len = seq_printf(m, "%d\n", major);
30
 #endif
31
 
32
+#endif
33
+
34
     KCL_DEBUG1(FN_FIREGL_PROC, "return len=%i\n",len);
35
 
36
     return len;
37
@@ -3432,7 +3439,11 @@ int ATI_API_CALL KCL_MEM_MTRR_Support(void)
38
 int ATI_API_CALL KCL_MEM_MTRR_AddRegionWc(unsigned long base, unsigned long size)
39
 {
40
 #ifdef CONFIG_MTRR
41
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0)
42
+    return arch_phys_wc_add(base, size);
43
+#else
44
     return mtrr_add(base, size, MTRR_TYPE_WRCOMB, 1);
45
+#endif
46
 #else /* !CONFIG_MTRR */
47
     return -EPERM;
48
 #endif /* !CONFIG_MTRR */
49
@@ -3441,7 +3452,12 @@ int ATI_API_CALL KCL_MEM_MTRR_AddRegionWc(unsigned long base, unsigned long size
50
 int ATI_API_CALL KCL_MEM_MTRR_DeleteRegion(int reg, unsigned long base, unsigned long size)
51
 {
52
 #ifdef CONFIG_MTRR
53
+#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,3,0)
54
+    arch_phys_wc_del(reg);
55
+    return 0;
56
+#else
57
     return mtrr_del(reg, base, size);
58
+#endif
59
 #else /* !CONFIG_MTRR */
60
     return -EPERM;
61
 #endif /* !CONFIG_MTRR */
62
@@ -6505,8 +6521,13 @@ static int KCL_fpu_save_init(struct task_struct *tsk)
63
       if (!(fpu->state->xsave.xsave_hdr.xstate_bv & XSTATE_FP))
  • Git repository management for enterprise teams powered by Atlassian Bitbucket
  • Atlassian Bitbucket v6.7.2
  • Documentation
  • Request a feature
  • About
  • Contact Atlassian
Atlassian

Everything looks good. We'll let you know here if there's anything you should know about.