1 Index: linux-2.4.35.4/arch/mips/kernel/mips_ksyms.c
2 ===================================================================
3 --- linux-2.4.35.4.orig/arch/mips/kernel/mips_ksyms.c 2007-12-15 05:19:41.186768139 +0100
4 +++ linux-2.4.35.4/arch/mips/kernel/mips_ksyms.c 2007-12-15 05:19:54.695537960 +0100
6 #include <asm/floppy.h>
9 +asmlinkage long long __ashldi3 (long long, int);
10 +asmlinkage long long __ashrdi3 (long long, int);
11 +asmlinkage long long __lshrdi3 (long long, int);
12 +asmlinkage long long __muldi3 (long long, long long);
13 extern void *__bzero(void *__s, size_t __count);
14 extern long __strncpy_from_user_nocheck_asm(char *__to,
15 const char *__from, long __len);
17 EXPORT_SYMBOL_NOVERS(__strnlen_user_asm);
21 +EXPORT_SYMBOL_NOVERS(__ashldi3);
22 +EXPORT_SYMBOL_NOVERS(__ashrdi3);
23 +EXPORT_SYMBOL_NOVERS(__lshrdi3);
24 +EXPORT_SYMBOL_NOVERS(__muldi3);
27 /* Networking helper routines. */
28 EXPORT_SYMBOL(csum_partial_copy);
30 Index: linux-2.4.35.4/arch/mips/lib/Makefile
31 ===================================================================
32 --- linux-2.4.35.4.orig/arch/mips/lib/Makefile 2007-12-15 05:19:41.194768595 +0100
33 +++ linux-2.4.35.4/arch/mips/lib/Makefile 2007-12-15 05:19:54.699538186 +0100
35 obj-y += csum_partial.o csum_partial_copy.o \
36 promlib.o rtc-std.o rtc-no.o memcpy.o \
37 memset.o watch.o strlen_user.o \
38 - strncpy_user.o strnlen_user.o
39 + strncpy_user.o strnlen_user.o \
40 + ashldi3.o ashrdi3.o lshrdi3.o muldi3.o
42 export-objs := rtc-std.o rtc-no.o
44 Index: linux-2.4.35.4/arch/mips/lib/ashldi3.c
45 ===================================================================
46 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
47 +++ linux-2.4.35.4/arch/mips/lib/ashldi3.c 2007-12-15 05:19:54.707538644 +0100
49 +/* ashrdi3.c extracted from gcc-2.95.2/libgcc2.c which is: */
50 +/* Copyright (C) 1989, 92-98, 1999 Free Software Foundation, Inc.
52 +This file is part of GNU CC.
54 +GNU CC is free software; you can redistribute it and/or modify
55 +it under the terms of the GNU General Public License as published by
56 +the Free Software Foundation; either version 2, or (at your option)
59 +GNU CC is distributed in the hope that it will be useful,
60 +but WITHOUT ANY WARRANTY; without even the implied warranty of
61 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
62 +GNU General Public License for more details.
64 +You should have received a copy of the GNU General Public License
65 +along with GNU CC; see the file COPYING. If not, write to
66 +the Free Software Foundation, 59 Temple Place - Suite 330,
67 +Boston, MA 02111-1307, USA. */
69 +#define BITS_PER_UNIT 8
71 +typedef int SItype __attribute__ ((mode (SI)));
72 +typedef unsigned int USItype __attribute__ ((mode (SI)));
73 +typedef int DItype __attribute__ ((mode (DI)));
74 +typedef int word_type __attribute__ ((mode (__word__)));
76 +struct DIstruct {SItype high, low;};
85 +__ashldi3 (DItype u, word_type b)
96 + bm = (sizeof (SItype) * BITS_PER_UNIT) - b;
100 + w.s.high = (USItype)uu.s.low << -bm;
104 + USItype carries = (USItype)uu.s.low >> bm;
105 + w.s.low = (USItype)uu.s.low << b;
106 + w.s.high = ((USItype)uu.s.high << b) | carries;
111 Index: linux-2.4.35.4/arch/mips/lib/ashrdi3.c
112 ===================================================================
113 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
114 +++ linux-2.4.35.4/arch/mips/lib/ashrdi3.c 2007-12-15 05:19:54.711538870 +0100
116 +/* ashrdi3.c extracted from gcc-2.7.2/libgcc2.c which is: */
117 +/* Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
119 +This file is part of GNU CC.
121 +GNU CC is free software; you can redistribute it and/or modify
122 +it under the terms of the GNU General Public License as published by
123 +the Free Software Foundation; either version 2, or (at your option)
126 +GNU CC is distributed in the hope that it will be useful,
127 +but WITHOUT ANY WARRANTY; without even the implied warranty of
128 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
129 +GNU General Public License for more details.
131 +You should have received a copy of the GNU General Public License
132 +along with GNU CC; see the file COPYING. If not, write to
133 +the Free Software Foundation, 59 Temple Place - Suite 330,
134 +Boston, MA 02111-1307, USA. */
136 +#define BITS_PER_UNIT 8
138 +typedef int SItype __attribute__ ((mode (SI)));
139 +typedef unsigned int USItype __attribute__ ((mode (SI)));
140 +typedef int DItype __attribute__ ((mode (DI)));
141 +typedef int word_type __attribute__ ((mode (__word__)));
143 +struct DIstruct {SItype high, low;};
152 +__ashrdi3 (DItype u, word_type b)
163 + bm = (sizeof (SItype) * BITS_PER_UNIT) - b;
166 + /* w.s.high = 1..1 or 0..0 */
167 + w.s.high = uu.s.high >> (sizeof (SItype) * BITS_PER_UNIT - 1);
168 + w.s.low = uu.s.high >> -bm;
172 + USItype carries = (USItype)uu.s.high << bm;
173 + w.s.high = uu.s.high >> b;
174 + w.s.low = ((USItype)uu.s.low >> b) | carries;
179 Index: linux-2.4.35.4/arch/mips/lib/lshrdi3.c
180 ===================================================================
181 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
182 +++ linux-2.4.35.4/arch/mips/lib/lshrdi3.c 2007-12-15 05:19:54.715539100 +0100
184 +/* lshrdi3.c extracted from gcc-2.7.2/libgcc2.c which is: */
185 +/* Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
187 +This file is part of GNU CC.
189 +GNU CC is free software; you can redistribute it and/or modify
190 +it under the terms of the GNU General Public License as published by
191 +the Free Software Foundation; either version 2, or (at your option)
194 +GNU CC is distributed in the hope that it will be useful,
195 +but WITHOUT ANY WARRANTY; without even the implied warranty of
196 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
197 +GNU General Public License for more details.
199 +You should have received a copy of the GNU General Public License
200 +along with GNU CC; see the file COPYING. If not, write to
201 +the Free Software Foundation, 59 Temple Place - Suite 330,
202 +Boston, MA 02111-1307, USA. */
204 +#define BITS_PER_UNIT 8
206 +typedef int SItype __attribute__ ((mode (SI)));
207 +typedef unsigned int USItype __attribute__ ((mode (SI)));
208 +typedef int DItype __attribute__ ((mode (DI)));
209 +typedef int word_type __attribute__ ((mode (__word__)));
211 +struct DIstruct {SItype high, low;};
220 +__lshrdi3 (DItype u, word_type b)
231 + bm = (sizeof (SItype) * BITS_PER_UNIT) - b;
235 + w.s.low = (USItype)uu.s.high >> -bm;
239 + USItype carries = (USItype)uu.s.high << bm;
240 + w.s.high = (USItype)uu.s.high >> b;
241 + w.s.low = ((USItype)uu.s.low >> b) | carries;
246 Index: linux-2.4.35.4/arch/mips/lib/muldi3.c
247 ===================================================================
248 --- /dev/null 1970-01-01 00:00:00.000000000 +0000
249 +++ linux-2.4.35.4/arch/mips/lib/muldi3.c 2007-12-15 05:19:54.715539100 +0100
251 +/* muldi3.c extracted from gcc-2.7.2.3/libgcc2.c and
252 + gcc-2.7.2.3/longlong.h which is: */
253 +/* Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
255 +This file is part of GNU CC.
257 +GNU CC is free software; you can redistribute it and/or modify
258 +it under the terms of the GNU General Public License as published by
259 +the Free Software Foundation; either version 2, or (at your option)
262 +GNU CC is distributed in the hope that it will be useful,
263 +but WITHOUT ANY WARRANTY; without even the implied warranty of
264 +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
265 +GNU General Public License for more details.
267 +You should have received a copy of the GNU General Public License
268 +along with GNU CC; see the file COPYING. If not, write to
269 +the Free Software Foundation, 59 Temple Place - Suite 330,
270 +Boston, MA 02111-1307, USA. */
272 +#define BITS_PER_UNIT 8
274 +#define umul_ppmm(w1, w0, u, v) \
275 + __asm__ ("multu %2,%3" \
276 + : "=l" ((USItype)(w0)), \
277 + "=h" ((USItype)(w1)) \
278 + : "d" ((USItype)(u)), \
279 + "d" ((USItype)(v)))
281 +#define __umulsidi3(u, v) \
283 + umul_ppmm (__w.s.high, __w.s.low, u, v); \
286 +typedef int SItype __attribute__ ((mode (SI)));
287 +typedef unsigned int USItype __attribute__ ((mode (SI)));
288 +typedef int DItype __attribute__ ((mode (DI)));
289 +typedef int word_type __attribute__ ((mode (__word__)));
291 +struct DIstruct {SItype high, low;};
300 +__muldi3 (DItype u, DItype v)
308 + w.ll = __umulsidi3 (uu.s.low, vv.s.low);
309 + w.s.high += ((USItype) uu.s.low * (USItype) vv.s.high
310 + + (USItype) uu.s.high * (USItype) vv.s.low);
314 Index: linux-2.4.35.4/fs/cifs/cifsfs.c
315 ===================================================================
316 --- linux-2.4.35.4.orig/fs/cifs/cifsfs.c 2007-12-15 05:19:52.279400271 +0100
317 +++ linux-2.4.35.4/fs/cifs/cifsfs.c 2007-12-15 05:19:54.715539100 +0100
319 static struct quotactl_ops cifs_quotactl_ops;
322 -extern struct file_system_type cifs_fs_type;
327 Index: linux-2.4.35.4/include/asm-mips/uaccess.h
328 ===================================================================
329 --- linux-2.4.35.4.orig/include/asm-mips/uaccess.h 2007-12-15 05:19:41.238771101 +0100
330 +++ linux-2.4.35.4/include/asm-mips/uaccess.h 2007-12-15 05:19:54.715539100 +0100
332 * Returns zero on success, or -EFAULT on error.
334 #define put_user(x,ptr) \
335 - __put_user_check((__typeof__(*(ptr)))(x),(ptr),sizeof(*(ptr)))
336 + __put_user_check((x),(ptr),sizeof(*(ptr)))
339 * get_user: - Get a simple variable from user space.
341 * On error, the variable @x is set to zero.
343 #define get_user(x,ptr) \
344 - __get_user_check((__typeof__(*(ptr)))(x),(ptr),sizeof(*(ptr)))
345 + __get_user_check((x),(ptr),sizeof(*(ptr)))
348 * __put_user: - Write a simple value into user space, with less checking.
350 * Returns zero on success, or -EFAULT on error.
352 #define __put_user(x,ptr) \
353 - __put_user_nocheck((__typeof__(*(ptr)))(x),(ptr),sizeof(*(ptr)))
354 + __put_user_nocheck((x),(ptr),sizeof(*(ptr)))
357 * __get_user: - Get a simple variable from user space, with less checking.
359 * On error, the variable @x is set to zero.
361 #define __get_user(x,ptr) \
362 - __get_user_nocheck((__typeof__(*(ptr)))(x),(ptr),sizeof(*(ptr)))
363 + __get_user_nocheck((x),(ptr),sizeof(*(ptr)))
365 struct __large_struct { unsigned long buf[100]; };
366 #define __m(x) (*(struct __large_struct *)(x))
368 #define __get_user_nocheck(x,ptr,size) \
371 - __typeof(*(ptr)) __gu_val = 0; \
372 + __typeof(*(ptr)) __gu_val = (__typeof(*(ptr))) 0; \
374 __gu_addr = (long) (ptr); \