diff options
author | Chaehyun Lim <chaehyun.lim@gmail.com> | 2015-09-22 18:34:55 +0900 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-09-29 02:29:51 +0200 |
commit | 27a82ebf920123978d74d51fe7ce94579e372f94 (patch) | |
tree | c953407263342c2536a25de14b950f267f6ace8e /drivers/staging/wilc1000 | |
parent | staging: wilc1000: host_int_init: remove meaningless comment (diff) | |
download | linux-dev-27a82ebf920123978d74d51fe7ce94579e372f94.tar.xz linux-dev-27a82ebf920123978d74d51fe7ce94579e372f94.zip |
staging: wilc1000: host_int_init: replace kmalloc with kzalloc
This patch replaces kmalloc with kzalloc in host_int_init.
Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/wilc1000')
-rw-r--r-- | drivers/staging/wilc1000/host_interface.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c index e7b3af3ef468..3f922169d6e9 100644 --- a/drivers/staging/wilc1000/host_interface.c +++ b/drivers/staging/wilc1000/host_interface.c @@ -6373,13 +6373,12 @@ s32 host_int_init(tstrWILC_WFIDrv **phWFIDrv) /*Allocate host interface private structure*/ - pstrWFIDrv = kmalloc(sizeof(tstrWILC_WFIDrv), GFP_KERNEL); + pstrWFIDrv = kzalloc(sizeof(tstrWILC_WFIDrv), GFP_KERNEL); if (pstrWFIDrv == NULL) { s32Error = -ENOMEM; PRINT_ER("Failed to allocate memory\n"); goto _fail_timer_2; } - memset(pstrWFIDrv, 0, sizeof(tstrWILC_WFIDrv)); *phWFIDrv = pstrWFIDrv; err = add_handler_in_list(pstrWFIDrv); if (err) { |