sunrpc_syms.c 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  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. #include <linux/module.h>
  9. #include <linux/types.h>
  10. #include <linux/uio.h>
  11. #include <linux/unistd.h>
  12. #include <linux/init.h>
  13. #include <linux/sunrpc/sched.h>
  14. #include <linux/sunrpc/clnt.h>
  15. #include <linux/sunrpc/svc.h>
  16. #include <linux/sunrpc/svcsock.h>
  17. #include <linux/sunrpc/auth.h>
  18. #include <linux/workqueue.h>
  19. #include <linux/sunrpc/rpc_pipe_fs.h>
  20. #include <linux/sunrpc/xprtsock.h>
  21. extern struct cache_detail ip_map_cache, unix_gid_cache;
  22. static int __init
  23. init_sunrpc(void)
  24. {
  25. int err = register_rpc_pipefs();
  26. if (err)
  27. goto out;
  28. err = rpc_init_mempool();
  29. if (err) {
  30. unregister_rpc_pipefs();
  31. goto out;
  32. }
  33. #ifdef RPC_DEBUG
  34. rpc_register_sysctl();
  35. #endif
  36. #ifdef CONFIG_PROC_FS
  37. rpc_proc_init();
  38. #endif
  39. cache_register(&ip_map_cache);
  40. cache_register(&unix_gid_cache);
  41. svc_init_xprt_sock(); /* svc sock transport */
  42. init_socket_xprt(); /* clnt sock transport */
  43. rpcauth_init_module();
  44. out:
  45. return err;
  46. }
  47. static void __exit
  48. cleanup_sunrpc(void)
  49. {
  50. rpcauth_remove_module();
  51. cleanup_socket_xprt();
  52. svc_cleanup_xprt_sock();
  53. unregister_rpc_pipefs();
  54. rpc_destroy_mempool();
  55. cache_unregister(&ip_map_cache);
  56. cache_unregister(&unix_gid_cache);
  57. #ifdef RPC_DEBUG
  58. rpc_unregister_sysctl();
  59. #endif
  60. #ifdef CONFIG_PROC_FS
  61. rpc_proc_exit();
  62. #endif
  63. rcu_barrier(); /* Wait for completion of call_rcu()'s */
  64. }
  65. MODULE_LICENSE("GPL");
  66. module_init(init_sunrpc);
  67. module_exit(cleanup_sunrpc);