diff options
author | Eric Dumazet <eric.dumazet@gmail.com> | 2010-11-22 00:15:06 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-11-27 22:53:38 -0800 |
commit | 89bf67f1f080c947c92f8773482d9e57767ca292 (patch) | |
tree | ae492f5f31a32a4f838778cd34320da0bedf9dfd /drivers/net/cxgb4 | |
parent | fe6d2a38b2076cba515dc95b5dc1589a7ab51c17 (diff) | |
download | blackbird-op-linux-89bf67f1f080c947c92f8773482d9e57767ca292.tar.gz blackbird-op-linux-89bf67f1f080c947c92f8773482d9e57767ca292.zip |
drivers/net: use vzalloc()
Use vzalloc() and vzalloc_node() in net drivers
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Acked-by: Jon Mason <jon.mason@exar.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb4')
-rw-r--r-- | drivers/net/cxgb4/cxgb4_main.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_main.c index f50bc98310f8..848f89d19fb7 100644 --- a/drivers/net/cxgb4/cxgb4_main.c +++ b/drivers/net/cxgb4/cxgb4_main.c @@ -868,12 +868,10 @@ out: release_firmware(fw); */ void *t4_alloc_mem(size_t size) { - void *p = kmalloc(size, GFP_KERNEL); + void *p = kzalloc(size, GFP_KERNEL); if (!p) - p = vmalloc(size); - if (p) - memset(p, 0, size); + p = vzalloc(size); return p; } |