Browse Source

bfin, csky, m68k, sh: fix build regression

* xlat/cacheflush_flags.in: New file.
* cacheflush.c [M68K || BFIN || CSKY || SH] (cacheflush_flags): Remove,
include "xlat/cacheflush_flags.h" instead.

Fixes: v5.3~105 "Add xlat description structure"
Dmitry V. Levin 1 month ago
parent
commit
38be73781f
2 changed files with 24 additions and 34 deletions
  1. 3
    34
      cacheflush.c
  2. 21
    0
      xlat/cacheflush_flags.in

+ 3
- 34
cacheflush.c View File

@@ -18,19 +18,7 @@
18 18
 
19 19
 #ifdef M68K
20 20
 # include "xlat/cacheflush_scope.h"
21
-
22
-static const struct xlat cacheflush_flags[] = {
23
-# ifdef FLUSH_CACHE_BOTH
24
-	XLAT(FLUSH_CACHE_BOTH),
25
-# endif
26
-# ifdef FLUSH_CACHE_DATA
27
-	XLAT(FLUSH_CACHE_DATA),
28
-# endif
29
-# ifdef FLUSH_CACHE_INSN
30
-	XLAT(FLUSH_CACHE_INSN),
31
-# endif
32
-	XLAT_END
33
-};
21
+# include "xlat/cacheflush_flags.h"
34 22
 
35 23
 SYS_FUNC(cacheflush)
36 24
 {
@@ -50,12 +38,7 @@ SYS_FUNC(cacheflush)
50 38
 #endif /* M68K */
51 39
 
52 40
 #if defined(BFIN) || defined(CSKY)
53
-static const struct xlat cacheflush_flags[] = {
54
-	XLAT(ICACHE),
55
-	XLAT(DCACHE),
56
-	XLAT(BCACHE),
57
-	XLAT_END
58
-};
41
+# include "xlat/cacheflush_flags.h"
59 42
 
60 43
 SYS_FUNC(cacheflush)
61 44
 {
@@ -71,21 +54,7 @@ SYS_FUNC(cacheflush)
71 54
 #endif /* BFIN || CSKY */
72 55
 
73 56
 #ifdef SH
74
-static const struct xlat cacheflush_flags[] = {
75
-# ifdef CACHEFLUSH_D_INVAL
76
-	XLAT(CACHEFLUSH_D_INVAL),
77
-# endif
78
-# ifdef CACHEFLUSH_D_WB
79
-	XLAT(CACHEFLUSH_D_WB),
80
-# endif
81
-# ifdef CACHEFLUSH_D_PURGE
82
-	XLAT(CACHEFLUSH_D_PURGE),
83
-# endif
84
-# ifdef CACHEFLUSH_I
85
-	XLAT(CACHEFLUSH_I),
86
-# endif
87
-	XLAT_END
88
-};
57
+# include "xlat/cacheflush_flags.h"
89 58
 
90 59
 SYS_FUNC(cacheflush)
91 60
 {

+ 21
- 0
xlat/cacheflush_flags.in View File

@@ -0,0 +1,21 @@
1
+#if defined M68K
2
+
3
+FLUSH_CACHE_BOTH	3
4
+FLUSH_CACHE_DATA	1
5
+FLUSH_CACHE_INSN	2
6
+
7
+#elif defined BFIN || defined CSKY
8
+
9
+BCACHE	3
10
+ICACHE	1
11
+DCACHE	2
12
+
13
+#elif defined SH
14
+
15
+BCACHE	7
16
+ICACHE	4
17
+DCACHE	3
18
+CACHEFLUSH_D_INVAL	1
19
+CACHEFLUSH_D_WB		2
20
+
21
+#endif

Loading…
Cancel
Save