[adm5120] rewrite image generation
[openwrt.git] / target / linux / generic-2.4 / patches / 206-gcc_3.4_fixes.patch
1 diff -Nur linux-2.4.30/arch/mips/kernel/signal.c linux-2.4.30.openwrt/arch/mips/kernel/signal.c
2 --- linux-2.4.30/arch/mips/kernel/signal.c 2005-07-02 13:00:13.000000000 +0200
3 +++ linux-2.4.30.openwrt/arch/mips/kernel/signal.c 2005-07-02 13:00:49.000000000 +0200
4 @@ -6,8 +6,10 @@
5 * Copyright (C) 1991, 1992 Linus Torvalds
6 * Copyright (C) 1994 - 1999 Ralf Baechle
7 * Copyright (C) 1999 Silicon Graphics, Inc.
8 + * Copyright (C) 2004 Maciej W. Rozycki
9 */
10 #include <linux/config.h>
11 +#include <linux/compiler.h>
12 #include <linux/sched.h>
13 #include <linux/mm.h>
14 #include <linux/smp.h>
15 @@ -76,7 +78,9 @@
16 * Atomically swap in the new signal mask, and wait for a signal.
17 */
18 save_static_function(sys_sigsuspend);
19 -static_unused int _sys_sigsuspend(struct pt_regs regs)
20 +static int _sys_sigsuspend(struct pt_regs regs)
21 + __asm__("_sys_sigsuspend") __attribute_used__;
22 +static int _sys_sigsuspend(struct pt_regs regs)
23 {
24 sigset_t *uset, saveset, newset;
25
26 @@ -102,7 +106,9 @@
27 }
28
29 save_static_function(sys_rt_sigsuspend);
30 -static_unused int _sys_rt_sigsuspend(struct pt_regs regs)
31 +static int _sys_rt_sigsuspend(struct pt_regs regs)
32 + __asm__("_sys_rt_sigsuspend") __attribute_used__;
33 +static int _sys_rt_sigsuspend(struct pt_regs regs)
34 {
35 sigset_t *unewset, saveset, newset;
36 size_t sigsetsize;
37 diff -Nur linux-2.4.30/arch/mips/kernel/syscall.c linux-2.4.30.openwrt/arch/mips/kernel/syscall.c
38 --- linux-2.4.30/arch/mips/kernel/syscall.c 2005-07-02 13:00:13.000000000 +0200
39 +++ linux-2.4.30.openwrt/arch/mips/kernel/syscall.c 2005-07-02 13:00:49.000000000 +0200
40 @@ -5,6 +5,7 @@
41 *
42 * Copyright (C) 1995 - 2000 by Ralf Baechle
43 * Copyright (C) 2000 Silicon Graphics, Inc.
44 + * Copyright (C) 2004 Maciej W. Rozycki
45 *
46 * TODO: Implement the compatibility syscalls.
47 * Don't waste that much memory for empty entries in the syscall
48 @@ -158,7 +159,9 @@
49 }
50
51 save_static_function(sys_fork);
52 -static_unused int _sys_fork(struct pt_regs regs)
53 +static int _sys_fork(struct pt_regs regs)
54 + __asm__("_sys_fork") __attribute_used__;
55 +static int _sys_fork(struct pt_regs regs)
56 {
57 int res;
58
59 @@ -168,7 +171,9 @@
60
61
62 save_static_function(sys_clone);
63 -static_unused int _sys_clone(struct pt_regs regs)
64 +static int _sys_clone(struct pt_regs regs)
65 + __asm__("_sys_clone") __attribute_used__;
66 +static int _sys_clone(struct pt_regs regs)
67 {
68 unsigned long clone_flags;
69 unsigned long newsp;
70 diff -Nur linux-2.4.30/arch/mips/ld.script.in linux-2.4.30.openwrt/arch/mips/ld.script.in
71 --- linux-2.4.30/arch/mips/ld.script.in 2005-07-02 13:00:22.000000000 +0200
72 +++ linux-2.4.30.openwrt/arch/mips/ld.script.in 2005-07-02 13:00:42.000000000 +0200
73 @@ -9,6 +9,7 @@
74 {
75 _ftext = . ;
76 *(.text)
77 + *(.fixup)
78 *(.rodata)
79 *(.rodata.*)
80 *(.rodata1)
81 diff -Nur linux-2.4.30/arch/mips64/kernel/signal.c linux-2.4.30.openwrt/arch/mips64/kernel/signal.c
82 --- linux-2.4.30/arch/mips64/kernel/signal.c 2005-07-02 13:00:13.000000000 +0200
83 +++ linux-2.4.30.openwrt/arch/mips64/kernel/signal.c 2005-07-02 13:00:49.000000000 +0200
84 @@ -6,8 +6,10 @@
85 * Copyright (C) 1991, 1992 Linus Torvalds
86 * Copyright (C) 1994 - 2000 Ralf Baechle
87 * Copyright (C) 1999, 2000 Silicon Graphics, Inc.
88 + * Copyright (C) 2004 Maciej W. Rozycki
89 */
90 #include <linux/config.h>
91 +#include <linux/compiler.h>
92 #include <linux/sched.h>
93 #include <linux/mm.h>
94 #include <linux/smp.h>
95 @@ -75,7 +77,9 @@
96 * Atomically swap in the new signal mask, and wait for a signal.
97 */
98 save_static_function(sys_rt_sigsuspend);
99 -static_unused int _sys_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
100 +static int _sys_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
101 + __asm__("_sys_rt_sigsuspend") __attribute_used__;
102 +static int _sys_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
103 {
104 sigset_t *unewset, saveset, newset;
105 size_t sigsetsize;
106 diff -Nur linux-2.4.30/arch/mips64/kernel/signal32.c linux-2.4.30.openwrt/arch/mips64/kernel/signal32.c
107 --- linux-2.4.30/arch/mips64/kernel/signal32.c 2005-07-02 13:00:13.000000000 +0200
108 +++ linux-2.4.30.openwrt/arch/mips64/kernel/signal32.c 2005-07-02 13:00:49.000000000 +0200
109 @@ -6,7 +6,9 @@
110 * Copyright (C) 1991, 1992 Linus Torvalds
111 * Copyright (C) 1994 - 2000 Ralf Baechle
112 * Copyright (C) 1999, 2000 Silicon Graphics, Inc.
113 + * Copyright (C) 2004 Maciej W. Rozycki
114 */
115 +#include <linux/compiler.h>
116 #include <linux/sched.h>
117 #include <linux/mm.h>
118 #include <linux/smp.h>
119 @@ -192,7 +194,9 @@
120 * Atomically swap in the new signal mask, and wait for a signal.
121 */
122 save_static_function(sys32_sigsuspend);
123 -static_unused int _sys32_sigsuspend(abi64_no_regargs, struct pt_regs regs)
124 +static int _sys32_sigsuspend(abi64_no_regargs, struct pt_regs regs)
125 + __asm__("_sys32_sigsuspend") __attribute_used__;
126 +static int _sys32_sigsuspend(abi64_no_regargs, struct pt_regs regs)
127 {
128 sigset32_t *uset;
129 sigset_t newset, saveset;
130 @@ -219,7 +223,9 @@
131 }
132
133 save_static_function(sys32_rt_sigsuspend);
134 -static_unused int _sys32_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
135 +static int _sys32_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
136 + __asm__("_sys32_rt_sigsuspend") __attribute_used__;
137 +static int _sys32_rt_sigsuspend(abi64_no_regargs, struct pt_regs regs)
138 {
139 sigset32_t *uset;
140 sigset_t newset, saveset;
141 diff -Nur linux-2.4.30/arch/mips64/kernel/syscall.c linux-2.4.30.openwrt/arch/mips64/kernel/syscall.c
142 --- linux-2.4.30/arch/mips64/kernel/syscall.c 2005-07-02 13:00:13.000000000 +0200
143 +++ linux-2.4.30.openwrt/arch/mips64/kernel/syscall.c 2005-07-02 13:00:49.000000000 +0200
144 @@ -6,7 +6,9 @@
145 * Copyright (C) 1995 - 2000, 2001 by Ralf Baechle
146 * Copyright (C) 1999, 2000 Silicon Graphics, Inc.
147 * Copyright (C) 2001 MIPS Technologies, Inc.
148 + * Copyright (C) 2004 Maciej W. Rozycki
149 */
150 +#include <linux/compiler.h>
151 #include <linux/errno.h>
152 #include <linux/linkage.h>
153 #include <linux/mm.h>
154 @@ -151,7 +153,9 @@
155 }
156
157 save_static_function(sys_fork);
158 -static_unused int _sys_fork(abi64_no_regargs, struct pt_regs regs)
159 +static int _sys_fork(abi64_no_regargs, struct pt_regs regs)
160 + __asm__("_sys_fork") __attribute_used__;
161 +static int _sys_fork(abi64_no_regargs, struct pt_regs regs)
162 {
163 int res;
164
165 @@ -160,7 +164,9 @@
166 }
167
168 save_static_function(sys_clone);
169 -static_unused int _sys_clone(abi64_no_regargs, struct pt_regs regs)
170 +static int _sys_clone(abi64_no_regargs, struct pt_regs regs)
171 + __asm__("_sys_clone") __attribute_used__;
172 +static int _sys_clone(abi64_no_regargs, struct pt_regs regs)
173 {
174 unsigned long clone_flags;
175 unsigned long newsp;
176 diff -Nur linux-2.4.30/include/asm-mips/ptrace.h linux-2.4.30.openwrt/include/asm-mips/ptrace.h
177 --- linux-2.4.30/include/asm-mips/ptrace.h 2005-07-02 13:00:13.000000000 +0200
178 +++ linux-2.4.30.openwrt/include/asm-mips/ptrace.h 2005-07-02 13:00:49.000000000 +0200
179 @@ -4,6 +4,7 @@
180 * for more details.
181 *
182 * Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000 by Ralf Baechle
183 + * Copyright (C) 2004 Maciej W. Rozycki
184 *
185 * Machine dependent structs and defines to help the user use
186 * the ptrace system call.
187 @@ -64,12 +65,10 @@
188 "sw\t$22,"__str(PT_R22)"($29)\n\t" \
189 "sw\t$23,"__str(PT_R23)"($29)\n\t" \
190 "sw\t$30,"__str(PT_R30)"($29)\n\t" \
191 + "j\t_" #symbol "\n\t" \
192 ".end\t" #symbol "\n\t" \
193 ".size\t" #symbol",. - " #symbol)
194
195 -/* Used in declaration of save_static functions. */
196 -#define static_unused static __attribute__((unused))
197 -
198 #endif /* !__ASSEMBLY__ */
199
200 /* Arbitrarily choose the same ptrace numbers as used by the Sparc code. */
201 diff -Nur linux-2.4.30/include/asm-mips64/ptrace.h linux-2.4.30.openwrt/include/asm-mips64/ptrace.h
202 --- linux-2.4.30/include/asm-mips64/ptrace.h 2005-07-02 13:00:13.000000000 +0200
203 +++ linux-2.4.30.openwrt/include/asm-mips64/ptrace.h 2005-07-02 13:00:49.000000000 +0200
204 @@ -5,6 +5,7 @@
205 *
206 * Copyright (C) 1994, 95, 96, 97, 98, 99, 2000 by Ralf Baechle
207 * Copyright (C) 1999, 2000 Silicon Graphics, Inc.
208 + * Copyright (C) 2004 Maciej W. Rozycki
209 */
210 #ifndef _ASM_PTRACE_H
211 #define _ASM_PTRACE_H
212 @@ -61,12 +62,10 @@
213 "sd\t$22,"__str(PT_R22)"($29)\n\t" \
214 "sd\t$23,"__str(PT_R23)"($29)\n\t" \
215 "sd\t$30,"__str(PT_R30)"($29)\n\t" \
216 + "j\t_" #symbol "\n\t" \
217 ".end\t" #symbol "\n\t" \
218 ".size\t" #symbol",. - " #symbol)
219
220 -/* Used in declaration of save_static functions. */
221 -#define static_unused static __attribute__((unused))
222 -
223 #define abi64_no_regargs \
224 unsigned long __dummy0, \
225 unsigned long __dummy1, \
This page took 0.060222 seconds and 5 git commands to generate.