NFSv4: Clean up nfs4_call_async()
[linux-2.6] / net / sunrpc / sunrpc_syms.c
1 /*
2  * linux/net/sunrpc/sunrpc_syms.c
3  *
4  * Symbols exported by the sunrpc module.
5  *
6  * Copyright (C) 1997 Olaf Kirch <okir@monad.swb.de>
7  */
8
9 #include <linux/module.h>
10
11 #include <linux/types.h>
12 #include <linux/uio.h>
13 #include <linux/unistd.h>
14 #include <linux/init.h>
15
16 #include <linux/sunrpc/sched.h>
17 #include <linux/sunrpc/clnt.h>
18 #include <linux/sunrpc/svc.h>
19 #include <linux/sunrpc/svcsock.h>
20 #include <linux/sunrpc/auth.h>
21 #include <linux/workqueue.h>
22 #include <linux/sunrpc/rpc_pipe_fs.h>
23
24
25 /* RPC scheduler */
26 EXPORT_SYMBOL(rpc_execute);
27 EXPORT_SYMBOL(rpc_init_task);
28 EXPORT_SYMBOL(rpc_sleep_on);
29 EXPORT_SYMBOL(rpc_wake_up_next);
30 EXPORT_SYMBOL(rpc_wake_up_task);
31 EXPORT_SYMBOL(rpciod_down);
32 EXPORT_SYMBOL(rpciod_up);
33 EXPORT_SYMBOL(rpc_wake_up_status);
34
35 /* RPC client functions */
36 EXPORT_SYMBOL(rpc_clone_client);
37 EXPORT_SYMBOL(rpc_bind_new_program);
38 EXPORT_SYMBOL(rpc_destroy_client);
39 EXPORT_SYMBOL(rpc_shutdown_client);
40 EXPORT_SYMBOL(rpc_killall_tasks);
41 EXPORT_SYMBOL(rpc_call_sync);
42 EXPORT_SYMBOL(rpc_call_async);
43 EXPORT_SYMBOL(rpc_call_setup);
44 EXPORT_SYMBOL(rpc_clnt_sigmask);
45 EXPORT_SYMBOL(rpc_clnt_sigunmask);
46 EXPORT_SYMBOL(rpc_delay);
47 EXPORT_SYMBOL(rpc_restart_call);
48 EXPORT_SYMBOL(rpc_setbufsize);
49 EXPORT_SYMBOL(rpc_unlink);
50 EXPORT_SYMBOL(rpc_wake_up);
51 EXPORT_SYMBOL(rpc_queue_upcall);
52 EXPORT_SYMBOL(rpc_mkpipe);
53
54 /* Client transport */
55 EXPORT_SYMBOL(xprt_set_timeout);
56
57 /* Client credential cache */
58 EXPORT_SYMBOL(rpcauth_register);
59 EXPORT_SYMBOL(rpcauth_unregister);
60 EXPORT_SYMBOL(rpcauth_create);
61 EXPORT_SYMBOL(rpcauth_lookupcred);
62 EXPORT_SYMBOL(rpcauth_lookup_credcache);
63 EXPORT_SYMBOL(rpcauth_free_credcache);
64 EXPORT_SYMBOL(rpcauth_init_credcache);
65 EXPORT_SYMBOL(put_rpccred);
66
67 /* RPC server stuff */
68 EXPORT_SYMBOL(svc_create);
69 EXPORT_SYMBOL(svc_create_thread);
70 EXPORT_SYMBOL(svc_create_pooled);
71 EXPORT_SYMBOL(svc_set_num_threads);
72 EXPORT_SYMBOL(svc_exit_thread);
73 EXPORT_SYMBOL(svc_destroy);
74 EXPORT_SYMBOL(svc_drop);
75 EXPORT_SYMBOL(svc_process);
76 EXPORT_SYMBOL(svc_recv);
77 EXPORT_SYMBOL(svc_wake_up);
78 EXPORT_SYMBOL(svc_makesock);
79 EXPORT_SYMBOL(svc_reserve);
80 EXPORT_SYMBOL(svc_auth_register);
81 EXPORT_SYMBOL(auth_domain_lookup);
82 EXPORT_SYMBOL(svc_authenticate);
83 EXPORT_SYMBOL(svc_set_client);
84
85 /* RPC statistics */
86 #ifdef CONFIG_PROC_FS
87 EXPORT_SYMBOL(rpc_proc_register);
88 EXPORT_SYMBOL(rpc_proc_unregister);
89 EXPORT_SYMBOL(svc_proc_register);
90 EXPORT_SYMBOL(svc_proc_unregister);
91 EXPORT_SYMBOL(svc_seq_show);
92 #endif
93
94 /* caching... */
95 EXPORT_SYMBOL(auth_domain_find);
96 EXPORT_SYMBOL(auth_domain_put);
97 EXPORT_SYMBOL(auth_unix_add_addr);
98 EXPORT_SYMBOL(auth_unix_forget_old);
99 EXPORT_SYMBOL(auth_unix_lookup);
100 EXPORT_SYMBOL(cache_check);
101 EXPORT_SYMBOL(cache_flush);
102 EXPORT_SYMBOL(cache_purge);
103 EXPORT_SYMBOL(cache_register);
104 EXPORT_SYMBOL(cache_unregister);
105 EXPORT_SYMBOL(qword_add);
106 EXPORT_SYMBOL(qword_addhex);
107 EXPORT_SYMBOL(qword_get);
108 EXPORT_SYMBOL(svcauth_unix_purge);
109 EXPORT_SYMBOL(unix_domain_find);
110
111 /* Generic XDR */
112 EXPORT_SYMBOL(xdr_encode_string);
113 EXPORT_SYMBOL(xdr_decode_string_inplace);
114 EXPORT_SYMBOL(xdr_decode_netobj);
115 EXPORT_SYMBOL(xdr_encode_netobj);
116 EXPORT_SYMBOL(xdr_encode_pages);
117 EXPORT_SYMBOL(xdr_inline_pages);
118 EXPORT_SYMBOL(xdr_shift_buf);
119 EXPORT_SYMBOL(xdr_encode_word);
120 EXPORT_SYMBOL(xdr_decode_word);
121 EXPORT_SYMBOL(xdr_encode_array2);
122 EXPORT_SYMBOL(xdr_decode_array2);
123 EXPORT_SYMBOL(xdr_buf_from_iov);
124 EXPORT_SYMBOL(xdr_buf_subsegment);
125 EXPORT_SYMBOL(xdr_buf_read_netobj);
126 EXPORT_SYMBOL(read_bytes_from_xdr_buf);
127
128 /* Debugging symbols */
129 #ifdef RPC_DEBUG
130 EXPORT_SYMBOL(rpc_debug);
131 EXPORT_SYMBOL(nfs_debug);
132 EXPORT_SYMBOL(nfsd_debug);
133 EXPORT_SYMBOL(nlm_debug);
134 #endif
135
136 extern struct cache_detail ip_map_cache, unix_gid_cache;
137
138 static int __init
139 init_sunrpc(void)
140 {
141         int err = register_rpc_pipefs();
142         if (err)
143                 goto out;
144         err = rpc_init_mempool();
145         if (err) {
146                 unregister_rpc_pipefs();
147                 goto out;
148         }
149 #ifdef RPC_DEBUG
150         rpc_register_sysctl();
151 #endif
152 #ifdef CONFIG_PROC_FS
153         rpc_proc_init();
154 #endif
155         cache_register(&ip_map_cache);
156         cache_register(&unix_gid_cache);
157         init_socket_xprt();
158 out:
159         return err;
160 }
161
162 static void __exit
163 cleanup_sunrpc(void)
164 {
165         cleanup_socket_xprt();
166         unregister_rpc_pipefs();
167         rpc_destroy_mempool();
168         if (cache_unregister(&ip_map_cache))
169                 printk(KERN_ERR "sunrpc: failed to unregister ip_map cache\n");
170         if (cache_unregister(&unix_gid_cache))
171               printk(KERN_ERR "sunrpc: failed to unregister unix_gid cache\n");
172 #ifdef RPC_DEBUG
173         rpc_unregister_sysctl();
174 #endif
175 #ifdef CONFIG_PROC_FS
176         rpc_proc_exit();
177 #endif
178 }
179 MODULE_LICENSE("GPL");
180 module_init(init_sunrpc);
181 module_exit(cleanup_sunrpc);