blob: b713c44c6fb429c8da7bdfab8a4399a906df1050 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/*
2 * linux/arch/arm/kernel/armksyms.c
3 *
4 * Copyright (C) 2000 Russell King
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
10#include <linux/module.h>
11#include <linux/string.h>
12#include <linux/delay.h>
13#include <linux/in6.h>
14#include <linux/syscalls.h>
15
16#include <asm/checksum.h>
17#include <asm/io.h>
18#include <asm/system.h>
19#include <asm/uaccess.h>
20
21/*
22 * libgcc functions - functions that are used internally by the
23 * compiler... (prototypes are not correct though, but that
24 * doesn't really matter since they're not versioned).
25 */
26extern void __ashldi3(void);
27extern void __ashrdi3(void);
28extern void __divsi3(void);
29extern void __lshrdi3(void);
30extern void __modsi3(void);
31extern void __muldi3(void);
32extern void __ucmpdi2(void);
Linus Torvalds1da177e2005-04-16 15:20:36 -070033extern void __udivsi3(void);
34extern void __umodsi3(void);
35extern void __do_div64(void);
36
37extern void fpundefinstr(void);
38extern void fp_enter(void);
39
40/*
41 * This has a special calling convention; it doesn't
42 * modify any of the usual registers, except for LR.
43 */
44#define EXPORT_SYMBOL_ALIAS(sym,orig) \
45 const struct kernel_symbol __ksymtab_##sym \
46 __attribute__((section("__ksymtab"))) = \
47 { (unsigned long)&orig, #sym };
48
49/*
50 * floating point math emulator support.
51 * These symbols will never change their calling convention...
52 */
53EXPORT_SYMBOL_ALIAS(kern_fp_enter,fp_enter);
54EXPORT_SYMBOL_ALIAS(fp_printk,printk);
55EXPORT_SYMBOL_ALIAS(fp_send_sig,send_sig);
56
57EXPORT_SYMBOL(__backtrace);
58
59 /* platform dependent support */
60EXPORT_SYMBOL(__udelay);
61EXPORT_SYMBOL(__const_udelay);
62
63 /* networking */
64EXPORT_SYMBOL(csum_partial);
65EXPORT_SYMBOL(csum_partial_copy_nocheck);
66EXPORT_SYMBOL(__csum_ipv6_magic);
67
68 /* io */
69#ifndef __raw_readsb
70EXPORT_SYMBOL(__raw_readsb);
71#endif
72#ifndef __raw_readsw
73EXPORT_SYMBOL(__raw_readsw);
74#endif
75#ifndef __raw_readsl
76EXPORT_SYMBOL(__raw_readsl);
77#endif
78#ifndef __raw_writesb
79EXPORT_SYMBOL(__raw_writesb);
80#endif
81#ifndef __raw_writesw
82EXPORT_SYMBOL(__raw_writesw);
83#endif
84#ifndef __raw_writesl
85EXPORT_SYMBOL(__raw_writesl);
86#endif
87
88 /* string / mem functions */
89EXPORT_SYMBOL(strcpy);
90EXPORT_SYMBOL(strncpy);
91EXPORT_SYMBOL(strcat);
92EXPORT_SYMBOL(strncat);
93EXPORT_SYMBOL(strcmp);
94EXPORT_SYMBOL(strncmp);
95EXPORT_SYMBOL(strchr);
96EXPORT_SYMBOL(strlen);
97EXPORT_SYMBOL(strnlen);
98EXPORT_SYMBOL(strpbrk);
99EXPORT_SYMBOL(strrchr);
100EXPORT_SYMBOL(strstr);
101EXPORT_SYMBOL(memset);
102EXPORT_SYMBOL(memcpy);
103EXPORT_SYMBOL(memmove);
104EXPORT_SYMBOL(memcmp);
105EXPORT_SYMBOL(memscan);
106EXPORT_SYMBOL(memchr);
107EXPORT_SYMBOL(__memzero);
108
109 /* user mem (segment) */
110EXPORT_SYMBOL(__arch_copy_from_user);
111EXPORT_SYMBOL(__arch_copy_to_user);
112EXPORT_SYMBOL(__arch_clear_user);
113EXPORT_SYMBOL(__arch_strnlen_user);
114EXPORT_SYMBOL(__arch_strncpy_from_user);
115
116EXPORT_SYMBOL(__get_user_1);
117EXPORT_SYMBOL(__get_user_2);
118EXPORT_SYMBOL(__get_user_4);
119EXPORT_SYMBOL(__get_user_8);
120
121EXPORT_SYMBOL(__put_user_1);
122EXPORT_SYMBOL(__put_user_2);
123EXPORT_SYMBOL(__put_user_4);
124EXPORT_SYMBOL(__put_user_8);
125
126 /* gcc lib functions */
127EXPORT_SYMBOL(__ashldi3);
128EXPORT_SYMBOL(__ashrdi3);
129EXPORT_SYMBOL(__divsi3);
130EXPORT_SYMBOL(__lshrdi3);
131EXPORT_SYMBOL(__modsi3);
132EXPORT_SYMBOL(__muldi3);
133EXPORT_SYMBOL(__ucmpdi2);
Linus Torvalds1da177e2005-04-16 15:20:36 -0700134EXPORT_SYMBOL(__udivsi3);
135EXPORT_SYMBOL(__umodsi3);
136EXPORT_SYMBOL(__do_div64);
137
138 /* bitops */
139EXPORT_SYMBOL(_set_bit_le);
140EXPORT_SYMBOL(_test_and_set_bit_le);
141EXPORT_SYMBOL(_clear_bit_le);
142EXPORT_SYMBOL(_test_and_clear_bit_le);
143EXPORT_SYMBOL(_change_bit_le);
144EXPORT_SYMBOL(_test_and_change_bit_le);
145EXPORT_SYMBOL(_find_first_zero_bit_le);
146EXPORT_SYMBOL(_find_next_zero_bit_le);
147EXPORT_SYMBOL(_find_first_bit_le);
148EXPORT_SYMBOL(_find_next_bit_le);
149
150#ifdef __ARMEB__
151EXPORT_SYMBOL(_set_bit_be);
152EXPORT_SYMBOL(_test_and_set_bit_be);
153EXPORT_SYMBOL(_clear_bit_be);
154EXPORT_SYMBOL(_test_and_clear_bit_be);
155EXPORT_SYMBOL(_change_bit_be);
156EXPORT_SYMBOL(_test_and_change_bit_be);
157EXPORT_SYMBOL(_find_first_zero_bit_be);
158EXPORT_SYMBOL(_find_next_zero_bit_be);
159EXPORT_SYMBOL(_find_first_bit_be);
160EXPORT_SYMBOL(_find_next_bit_be);
161#endif
162
163 /* syscalls */
164EXPORT_SYMBOL(sys_write);
165EXPORT_SYMBOL(sys_read);
166EXPORT_SYMBOL(sys_lseek);
167EXPORT_SYMBOL(sys_open);
168EXPORT_SYMBOL(sys_exit);
169EXPORT_SYMBOL(sys_wait4);