treewide: Use array_size() in vzalloc()
[linux-block.git] / fs / nfsd / nfscache.c
index 334f2ad6070491d2302e93fd7fc87b6603c325f7..223b3b2dff87a989b7443b7570cdb12f035681e7 100644 (file)
@@ -177,7 +177,8 @@ int nfsd_reply_cache_init(void)
 
        drc_hashtbl = kcalloc(hashsize, sizeof(*drc_hashtbl), GFP_KERNEL);
        if (!drc_hashtbl) {
-               drc_hashtbl = vzalloc(hashsize * sizeof(*drc_hashtbl));
+               drc_hashtbl = vzalloc(array_size(hashsize,
+                                                sizeof(*drc_hashtbl)));
                if (!drc_hashtbl)
                        goto out_nomem;
        }