Merge to Fedora kernel-2.6.18-1.2224_FC5 patched with stable patch-2.6.18.1-vs2.0...
[linux-2.6.git] / net / sunrpc / stats.c
index 15c2db2..bd98124 100644 (file)
@@ -114,13 +114,8 @@ void svc_seq_show(struct seq_file *seq, const struct svc_stat *statp) {
  */
 struct rpc_iostats *rpc_alloc_iostats(struct rpc_clnt *clnt)
 {
-       unsigned int ops = clnt->cl_maxproc;
-       size_t size = ops * sizeof(struct rpc_iostats);
        struct rpc_iostats *new;
-
-       new = kmalloc(size, GFP_KERNEL);
-       if (new)
-               memset(new, 0 , size);
+       new = kcalloc(clnt->cl_maxproc, sizeof(struct rpc_iostats), GFP_KERNEL);
        return new;
 }
 EXPORT_SYMBOL(rpc_alloc_iostats);