staging: lustre: llite: Replace kmem_cache_alloc with kmem_cache_zalloc
authorAmitoj Kaur Chawla <amitoj1606@gmail.com>
Fri, 26 Feb 2016 08:55:09 +0000 (14:25 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 2 Mar 2016 03:18:42 +0000 (19:18 -0800)
commit21068c46f2067d4f2e201980388be0fa28fa0bfa
treeec164d00c2388afb570d228a30380005b1d4b77d
parent3eed2d000275d8b6352cffeb60e79e55239f1f16
staging: lustre: llite: Replace kmem_cache_alloc with kmem_cache_zalloc

Use kmem_cache_zalloc instead of manually setting kmem_cache_alloc
with flag GFP_ZERO since kmem_alloc_zalloc sets allocated memory
to zero.

The Coccinelle semantic patch used to make this change is as
follows:
// <smpl>
@@
expression e,f;
@@
- kmem_cache_alloc(e, f |__GFP_ZERO)
+ kmem_cache_zalloc(e, f)
// </smpl>

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/llite/file.c
drivers/staging/lustre/lustre/llite/llite_close.c
drivers/staging/lustre/lustre/llite/llite_lib.c
drivers/staging/lustre/lustre/llite/namei.c
drivers/staging/lustre/lustre/llite/remote_perm.c
drivers/staging/lustre/lustre/llite/super25.c
drivers/staging/lustre/lustre/llite/vvp_dev.c
drivers/staging/lustre/lustre/llite/xattr_cache.c