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/cxgb3 | |
parent | fe6d2a38b2076cba515dc95b5dc1589a7ab51c17 (diff) | |
download | op-kernel-dev-89bf67f1f080c947c92f8773482d9e57767ca292.zip op-kernel-dev-89bf67f1f080c947c92f8773482d9e57767ca292.tar.gz |
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/cxgb3')
-rw-r--r-- | drivers/net/cxgb3/cxgb3_offload.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/cxgb3/cxgb3_offload.c b/drivers/net/cxgb3/cxgb3_offload.c index bcf0753..ef02aa6 100644 --- a/drivers/net/cxgb3/cxgb3_offload.c +++ b/drivers/net/cxgb3/cxgb3_offload.c @@ -1164,12 +1164,10 @@ static void cxgb_redirect(struct dst_entry *old, struct dst_entry *new) */ void *cxgb_alloc_mem(unsigned long 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; } |