blob: f73c2240fe60b0a4b3718965071a05c7c7b9af90 [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);
Sam Ravnborg45536ff2009-01-08 16:57:35 -080065
66/* Alias functions whose names begin with "." and export the aliases.
67 * The module references will be fixed up by module_frob_arch_sections.
68 */
69extern int _Div(int, int);
70extern int _Mul(int, int);
71extern int _Rem(int, int);
72extern unsigned _Udiv(unsigned, unsigned);
73extern unsigned _Umul(unsigned, unsigned);
74extern unsigned _Urem(unsigned, unsigned);
75
76/* Networking helper routines. */
77EXPORT_SYMBOL(__csum_partial_copy_sparc_generic);
78
79/* Special internal versions of library functions. */
80EXPORT_SYMBOL(__copy_1page);
Sam Ravnborg45536ff2009-01-08 16:57:35 -080081EXPORT_SYMBOL(__memmove);
82EXPORT_SYMBOL(bzero_1page);
83
84/* string functions */
85EXPORT_SYMBOL(__strncmp);
86
87/* Moving data to/from/in userspace. */
88EXPORT_SYMBOL(__copy_user);
89
90/* Used by asm/spinlock.h */
91#ifdef CONFIG_SMP
92EXPORT_SYMBOL(___rw_read_enter);
93EXPORT_SYMBOL(___rw_read_try);
94EXPORT_SYMBOL(___rw_read_exit);
95EXPORT_SYMBOL(___rw_write_enter);
96#endif
97
Sam Ravnborg45536ff2009-01-08 16:57:35 -080098EXPORT_SYMBOL(__ashrdi3);
99EXPORT_SYMBOL(__ashldi3);
100EXPORT_SYMBOL(__lshrdi3);
101EXPORT_SYMBOL(__muldi3);
102EXPORT_SYMBOL(__divdi3);
103
104EXPORT_SYMBOL(_Rem);
105EXPORT_SYMBOL(_Urem);
106EXPORT_SYMBOL(_Mul);
107EXPORT_SYMBOL(_Umul);
108EXPORT_SYMBOL(_Div);
109EXPORT_SYMBOL(_Udiv);
110#endif
111
112/*
113 * sparc64
114 */
115#ifdef CONFIG_SPARC64
116/* Networking helper routines. */
117EXPORT_SYMBOL(csum_partial_copy_nocheck);
118EXPORT_SYMBOL(__csum_partial_copy_from_user);
119EXPORT_SYMBOL(__csum_partial_copy_to_user);
120EXPORT_SYMBOL(ip_fast_csum);
121
122/* Moving data to/from/in userspace. */
123EXPORT_SYMBOL(___copy_to_user);
124EXPORT_SYMBOL(___copy_from_user);
125EXPORT_SYMBOL(___copy_in_user);
126EXPORT_SYMBOL(__clear_user);
127
128/* RW semaphores */
129EXPORT_SYMBOL(__down_read);
130EXPORT_SYMBOL(__down_read_trylock);
131EXPORT_SYMBOL(__down_write);
132EXPORT_SYMBOL(__down_write_trylock);
133EXPORT_SYMBOL(__up_read);
134EXPORT_SYMBOL(__up_write);
135EXPORT_SYMBOL(__downgrade_write);
136
137/* Atomic counter implementation. */
138EXPORT_SYMBOL(atomic_add);
139EXPORT_SYMBOL(atomic_add_ret);
140EXPORT_SYMBOL(atomic_sub);
141EXPORT_SYMBOL(atomic_sub_ret);
142EXPORT_SYMBOL(atomic64_add);
143EXPORT_SYMBOL(atomic64_add_ret);
144EXPORT_SYMBOL(atomic64_sub);
145EXPORT_SYMBOL(atomic64_sub_ret);
146
147/* Atomic bit operations. */
148EXPORT_SYMBOL(test_and_set_bit);
149EXPORT_SYMBOL(test_and_clear_bit);
150EXPORT_SYMBOL(test_and_change_bit);
151EXPORT_SYMBOL(set_bit);
152EXPORT_SYMBOL(clear_bit);
153EXPORT_SYMBOL(change_bit);
154
155/* Special internal versions of library functions. */
156EXPORT_SYMBOL(_clear_page);
157EXPORT_SYMBOL(clear_user_page);
158EXPORT_SYMBOL(copy_user_page);
159
160/* RAID code needs this */
161void VISenter(void);
162EXPORT_SYMBOL(VISenter);
163
164extern void xor_vis_2(unsigned long, unsigned long *, unsigned long *);
165extern void xor_vis_3(unsigned long, unsigned long *, unsigned long *,
166 unsigned long *);
167extern void xor_vis_4(unsigned long, unsigned long *, unsigned long *,
168 unsigned long *, unsigned long *);
169extern void xor_vis_5(unsigned long, unsigned long *, unsigned long *,
170 unsigned long *, unsigned long *, unsigned long *);
171EXPORT_SYMBOL(xor_vis_2);
172EXPORT_SYMBOL(xor_vis_3);
173EXPORT_SYMBOL(xor_vis_4);
174EXPORT_SYMBOL(xor_vis_5);
175
176extern void xor_niagara_2(unsigned long, unsigned long *, unsigned long *);
177extern void xor_niagara_3(unsigned long, unsigned long *, unsigned long *,
178 unsigned long *);
179extern void xor_niagara_4(unsigned long, unsigned long *, unsigned long *,
180 unsigned long *, unsigned long *);
181extern void xor_niagara_5(unsigned long, unsigned long *, unsigned long *,
182 unsigned long *, unsigned long *, unsigned long *);
183
184EXPORT_SYMBOL(xor_niagara_2);
185EXPORT_SYMBOL(xor_niagara_3);
186EXPORT_SYMBOL(xor_niagara_4);
187EXPORT_SYMBOL(xor_niagara_5);
188#endif