aboutsummaryrefslogtreecommitdiffstats
path: root/net/sunrpc/sched.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2008-02-22 17:06:55 -0500
committerTrond Myklebust <Trond.Myklebust@netapp.com>2008-02-29 02:17:27 -0500
commitf6a1cc89309f0ae847a9b6fe418d1c4215e5bc55 (patch)
tree4f5d585dd901718d66d9c354625f9a0bc85c234d /net/sunrpc/sched.c
parent5d00837b90340af9106dcd93af75fd664c8eb87f (diff)
SUNRPC: Add a (empty for the moment) destructor for rpc_wait_queues
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/sched.c')
-rw-r--r--net/sunrpc/sched.c21
1 files changed, 14 insertions, 7 deletions
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c
index caf12fd6b6af..86aa897e7b08 100644
--- a/net/sunrpc/sched.c
+++ b/net/sunrpc/sched.c
@@ -214,6 +214,11 @@ void rpc_init_wait_queue(struct rpc_wait_queue *queue, const char *qname)
214} 214}
215EXPORT_SYMBOL_GPL(rpc_init_wait_queue); 215EXPORT_SYMBOL_GPL(rpc_init_wait_queue);
216 216
217void rpc_destroy_wait_queue(struct rpc_wait_queue *queue)
218{
219}
220EXPORT_SYMBOL_GPL(rpc_destroy_wait_queue);
221
217static int rpc_wait_bit_killable(void *word) 222static int rpc_wait_bit_killable(void *word)
218{ 223{
219 if (fatal_signal_pending(current)) 224 if (fatal_signal_pending(current))
@@ -1020,11 +1025,20 @@ rpc_destroy_mempool(void)
1020 kmem_cache_destroy(rpc_task_slabp); 1025 kmem_cache_destroy(rpc_task_slabp);
1021 if (rpc_buffer_slabp) 1026 if (rpc_buffer_slabp)
1022 kmem_cache_destroy(rpc_buffer_slabp); 1027 kmem_cache_destroy(rpc_buffer_slabp);
1028 rpc_destroy_wait_queue(&delay_queue);
1023} 1029}
1024 1030
1025int 1031int
1026rpc_init_mempool(void) 1032rpc_init_mempool(void)
1027{ 1033{
1034 /*
1035 * The following is not strictly a mempool initialisation,
1036 * but there is no harm in doing it here
1037 */
1038 rpc_init_wait_queue(&delay_queue, "delayq");
1039 if (!rpciod_start())
1040 goto err_nomem;
1041
1028 rpc_task_slabp = kmem_cache_create("rpc_tasks", 1042 rpc_task_slabp = kmem_cache_create("rpc_tasks",
1029 sizeof(struct rpc_task), 1043 sizeof(struct rpc_task),
1030 0, SLAB_HWCACHE_ALIGN, 1044 0, SLAB_HWCACHE_ALIGN,
@@ -1045,13 +1059,6 @@ rpc_init_mempool(void)
1045 rpc_buffer_slabp); 1059 rpc_buffer_slabp);
1046 if (!rpc_buffer_mempool) 1060 if (!rpc_buffer_mempool)
1047 goto err_nomem; 1061 goto err_nomem;
1048 if (!rpciod_start())
1049 goto err_nomem;
1050 /*
1051 * The following is not strictly a mempool initialisation,
1052 * but there is no harm in doing it here
1053 */
1054 rpc_init_wait_queue(&delay_queue, "delayq");
1055 return 0; 1062 return 0;
1056err_nomem: 1063err_nomem:
1057 rpc_destroy_mempool(); 1064 rpc_destroy_mempool();