blob: 1b30bb3bfdb1fe19f522aff9e46f64f212060086 [file] [log] [blame]
Sam Ravnborg45536ff2009-01-08 16:57:35 -08001/*
2 * Export of symbols defined in assembler
3 */
4
5/* Tell string.h we don't want memcpy etc. as cpp defines */
6#define EXPORT_SYMTAB_STROPS
7
8#include <linux/module.h>
9#include <linux/string.h>
10#include <linux/types.h>
11
12#include <asm/checksum.h>
13#include <asm/uaccess.h>
14#include <asm/ftrace.h>
15
16/* string functions */
17EXPORT_SYMBOL(strlen);
18EXPORT_SYMBOL(__strlen_user);
19EXPORT_SYMBOL(__strnlen_user);
20EXPORT_SYMBOL(strncmp);
21
22/* mem* functions */
23extern void *__memscan_zero(void *, size_t);
24extern void *__memscan_generic(void *, int, size_t);
25extern void *__bzero(void *, size_t);
26
27EXPORT_SYMBOL(memscan);
28EXPORT_SYMBOL(__memscan_zero);
29EXPORT_SYMBOL(__memscan_generic);
30EXPORT_SYMBOL(memcmp);
31EXPORT_SYMBOL(memcpy);
32EXPORT_SYMBOL(memset);
Sam Ravnborg45536ff2009-01-08 16:57:35 -080033EXPORT_SYMBOL(memmove);
34EXPORT_SYMBOL(__bzero);
35
36/* Moving data to/from/in userspace. */
37EXPORT_SYMBOL(__strncpy_from_user);
38
39/* Networking helper routines. */
40EXPORT_SYMBOL(csum_partial);
41
42#ifdef CONFIG_MCOUNT
43EXPORT_SYMBOL(_mcount);
44#endif
45
46/*
47 * sparc
48 */
49#ifdef CONFIG_SPARC32
50extern int __ashrdi3(int, int);
51extern int __ashldi3(int, int);
52extern int __lshrdi3(int, int);
53extern int __muldi3(int, int);
54extern int __divdi3(int, int);
55
56extern void (*__copy_1page)(void *, const void *);
57extern void (*bzero_1page)(void *);
58
59extern int __strncmp(const char *, const char *, __kernel_size_t);
60
61extern void ___rw_read_enter(void);
62extern void ___rw_read_try(void);
63extern void ___rw_read_exit(void);
64extern void ___rw_write_enter(void);
65extern void ___atomic24_add(void);
66extern void ___atomic24_sub(void);
67
68/* Alias functions whose names begin with "." and export the aliases.
69 * The module references will be fixed up by module_frob_arch_sections.
70 */
71extern int _Div(int, int);
72extern int _Mul(int, int);
73extern int _Rem(int, int);
74extern unsigned _Udiv(unsigned, unsigned);
75extern unsigned _Umul(unsigned, unsigned);
76extern unsigned _Urem(unsigned, unsigned);
77
78/* Networking helper routines. */
79EXPORT_SYMBOL(__csum_partial_copy_sparc_generic);
80
81/* Special internal versions of library functions. */
82EXPORT_SYMBOL(__copy_1page);
Sam Ravnborg45536ff2009-01-08 16:57:35 -080083EXPORT_SYMBOL(__memmove);
84EXPORT_SYMBOL(bzero_1page);
85
86/* string functions */
87EXPORT_SYMBOL(__strncmp);
88
89/* Moving data to/from/in userspace. */
90EXPORT_SYMBOL(__copy_user);
91
92/* Used by asm/spinlock.h */
93#ifdef CONFIG_SMP
94EXPORT_SYMBOL(___rw_read_enter);
95EXPORT_SYMBOL(___rw_read_try);
96EXPORT_SYMBOL(___rw_read_exit);
97EXPORT_SYMBOL(___rw_write_enter);
98#endif
99
100/* Atomic operations. */
101EXPORT_SYMBOL(___atomic24_add);
102EXPORT_SYMBOL(___atomic24_sub);
103
104EXPORT_SYMBOL(__ashrdi3);
105EXPORT_SYMBOL(__ashldi3);
106EXPORT_SYMBOL(__lshrdi3);
107EXPORT_SYMBOL(__muldi3);
108EXPORT_SYMBOL(__divdi3);
109
110EXPORT_SYMBOL(_Rem);
111EXPORT_SYMBOL(_Urem);
112EXPORT_SYMBOL(_Mul);
113EXPORT_SYMBOL(_Umul);
114EXPORT_SYMBOL(_Div);
115EXPORT_SYMBOL(_Udiv);
116#endif
117
118/*
119 * sparc64
120 */
121#ifdef CONFIG_SPARC64
122/* Networking helper routines. */
123EXPORT_SYMBOL(csum_partial_copy_nocheck);
124EXPORT_SYMBOL(__csum_partial_copy_from_user);
125EXPORT_SYMBOL(__csum_partial_copy_to_user);
126EXPORT_SYMBOL(ip_fast_csum);
127
128/* Moving data to/from/in userspace. */
129EXPORT_SYMBOL(___copy_to_user);
130EXPORT_SYMBOL(___copy_from_user);
131EXPORT_SYMBOL(___copy_in_user);
132EXPORT_SYMBOL(__clear_user);
133
134/* RW semaphores */
135EXPORT_SYMBOL(__down_read);
136EXPORT_SYMBOL(__down_read_trylock);
137EXPORT_SYMBOL(__down_write);
138EXPORT_SYMBOL(__down_write_trylock);
139EXPORT_SYMBOL(__up_read);
140EXPORT_SYMBOL(__up_write);
141EXPORT_SYMBOL(__downgrade_write);
142
143/* Atomic counter implementation. */
144EXPORT_SYMBOL(atomic_add);
145EXPORT_SYMBOL(atomic_add_ret);
146EXPORT_SYMBOL(atomic_sub);
147EXPORT_SYMBOL(atomic_sub_ret);
148EXPORT_SYMBOL(atomic64_add);
149EXPORT_SYMBOL(atomic64_add_ret);
150EXPORT_SYMBOL(atomic64_sub);
151EXPORT_SYMBOL(atomic64_sub_ret);
152
153/* Atomic bit operations. */
154EXPORT_SYMBOL(test_and_set_bit);
155EXPORT_SYMBOL(test_and_clear_bit);
156EXPORT_SYMBOL(test_and_change_bit);
157EXPORT_SYMBOL(set_bit);
158EXPORT_SYMBOL(clear_bit);
159EXPORT_SYMBOL(change_bit);
160
161/* Special internal versions of library functions. */
162EXPORT_SYMBOL(_clear_page);
163EXPORT_SYMBOL(clear_user_page);
164EXPORT_SYMBOL(copy_user_page);
165
166/* RAID code needs this */
167void VISenter(void);
168EXPORT_SYMBOL(VISenter);
169
170extern void xor_vis_2(unsigned long, unsigned long *, unsigned long *);
171extern void xor_vis_3(unsigned long, unsigned long *, unsigned long *,
172 unsigned long *);
173extern void xor_vis_4(unsigned long, unsigned long *, unsigned long *,
174 unsigned long *, unsigned long *);
175extern void xor_vis_5(unsigned long, unsigned long *, unsigned long *,
176 unsigned long *, unsigned long *, unsigned long *);
177EXPORT_SYMBOL(xor_vis_2);
178EXPORT_SYMBOL(xor_vis_3);
179EXPORT_SYMBOL(xor_vis_4);
180EXPORT_SYMBOL(xor_vis_5);
181
182extern void xor_niagara_2(unsigned long, unsigned long *, unsigned long *);
183extern void xor_niagara_3(unsigned long, unsigned long *, unsigned long *,
184 unsigned long *);
185extern void xor_niagara_4(unsigned long, unsigned long *, unsigned long *,
186 unsigned long *, unsigned long *);
187extern void xor_niagara_5(unsigned long, unsigned long *, unsigned long *,
188 unsigned long *, unsigned long *, unsigned long *);
189
190EXPORT_SYMBOL(xor_niagara_2);
191EXPORT_SYMBOL(xor_niagara_3);
192EXPORT_SYMBOL(xor_niagara_4);
193EXPORT_SYMBOL(xor_niagara_5);
194#endif