bcm63xx: make smp kernels boot on older SoCs
[openwrt/svn-archive/archive.git] / target / linux / brcm63xx / patches-3.9 / 100-MIPS-bmips-fix-compilation-for-BMIPS5000.patch
1 From d55975b74389b2cf1a38732062ff89303940f6e1 Mon Sep 17 00:00:00 2001
2 From: Jonas Gorski <jogo@openwrt.org>
3 Date: Sat, 29 Jun 2013 11:46:56 +0200
4 Subject: [PATCH 01/10] MIPS: bmips: fix compilation for BMIPS5000
5
6 Replace the macro names in strings with actual macro invocation.
7
8 Fixes the following build error:
9
10 CC arch/mips/kernel/smp-bmips.o
11 {standard input}: Assembler messages:
12 {standard input}:951: Error: Unrecognized opcode `_ssnop'
13 {standard input}:952: Error: Unrecognized opcode `_ssnop'
14 (...)
15 make[6]: *** [arch/mips/kernel/smp-bmips.o] Error 1
16
17 Signed-off-by: Jonas Gorski <jogo@openwrt.org>
18 ---
19 arch/mips/include/asm/bmips.h | 28 ++++++++++++++--------------
20 1 file changed, 14 insertions(+), 14 deletions(-)
21
22 --- a/arch/mips/include/asm/bmips.h
23 +++ b/arch/mips/include/asm/bmips.h
24 @@ -70,15 +70,15 @@ static inline unsigned long bmips_read_z
25 ".set noreorder\n"
26 "cache %1, 0(%2)\n"
27 "sync\n"
28 - "_ssnop\n"
29 - "_ssnop\n"
30 - "_ssnop\n"
31 - "_ssnop\n"
32 - "_ssnop\n"
33 - "_ssnop\n"
34 - "_ssnop\n"
35 + __stringify(___ssnop) "\n"
36 + __stringify(___ssnop) "\n"
37 + __stringify(___ssnop) "\n"
38 + __stringify(___ssnop) "\n"
39 + __stringify(___ssnop) "\n"
40 + __stringify(___ssnop) "\n"
41 + __stringify(___ssnop) "\n"
42 "mfc0 %0, $28, 3\n"
43 - "_ssnop\n"
44 + __stringify(___ssnop) "\n"
45 ".set pop\n"
46 : "=&r" (ret)
47 : "i" (Index_Load_Tag_S), "r" (ZSCM_REG_BASE + offset)
48 @@ -92,13 +92,13 @@ static inline void bmips_write_zscm_reg(
49 ".set push\n"
50 ".set noreorder\n"
51 "mtc0 %0, $28, 3\n"
52 - "_ssnop\n"
53 - "_ssnop\n"
54 - "_ssnop\n"
55 + __stringify(___ssnop) "\n"
56 + __stringify(___ssnop) "\n"
57 + __stringify(___ssnop) "\n"
58 "cache %1, 0(%2)\n"
59 - "_ssnop\n"
60 - "_ssnop\n"
61 - "_ssnop\n"
62 + __stringify(___ssnop) "\n"
63 + __stringify(___ssnop) "\n"
64 + __stringify(___ssnop) "\n"
65 : /* no outputs */
66 : "r" (data),
67 "i" (Index_Store_Tag_S), "r" (ZSCM_REG_BASE + offset)