mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
[PATCH] Transform kmem_cache_alloc()+memset(0) -> kmem_cache_zalloc().
Replace appropriate pairs of "kmem_cache_alloc()" + "memset(0)" with the corresponding "kmem_cache_zalloc()" call. Signed-off-by: Robert P. J. Day <[email protected]> Cc: "Luck, Tony" <[email protected]> Cc: Andi Kleen <[email protected]> Cc: Roland McGrath <[email protected]> Cc: James Bottomley <[email protected]> Cc: Greg KH <[email protected]> Acked-by: Joel Becker <[email protected]> Cc: Steven Whitehouse <[email protected]> Cc: Jan Kara <[email protected]> Cc: Michael Halcrow <[email protected]> Cc: "David S. Miller" <[email protected]> Cc: Stephen Smalley <[email protected]> Cc: James Morris <[email protected]> Cc: Chris Wright <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
1b135431ab
commit
c376222960
39 changed files with 48 additions and 103 deletions
|
|
@ -61,7 +61,7 @@ static struct smb_request *smb_do_alloc_request(struct smb_sb_info *server,
|
|||
struct smb_request *req;
|
||||
unsigned char *buf = NULL;
|
||||
|
||||
req = kmem_cache_alloc(req_cachep, GFP_KERNEL);
|
||||
req = kmem_cache_zalloc(req_cachep, GFP_KERNEL);
|
||||
VERBOSE("allocating request: %p\n", req);
|
||||
if (!req)
|
||||
goto out;
|
||||
|
|
@ -74,7 +74,6 @@ static struct smb_request *smb_do_alloc_request(struct smb_sb_info *server,
|
|||
}
|
||||
}
|
||||
|
||||
memset(req, 0, sizeof(struct smb_request));
|
||||
req->rq_buffer = buf;
|
||||
req->rq_bufsize = bufsize;
|
||||
req->rq_server = server;
|
||||
|
|
|
|||
Loading…
Reference in a new issue