[AX.25]: Use kzalloc
Replace kzalloc instead of kmalloc + memset. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
2478173464
commit
1b30dd359e
@@ -486,10 +486,9 @@ ax25_cb *ax25_create_cb(void)
|
||||
{
|
||||
ax25_cb *ax25;
|
||||
|
||||
if ((ax25 = kmalloc(sizeof(*ax25), GFP_ATOMIC)) == NULL)
|
||||
if ((ax25 = kzalloc(sizeof(*ax25), GFP_ATOMIC)) == NULL)
|
||||
return NULL;
|
||||
|
||||
memset(ax25, 0x00, sizeof(*ax25));
|
||||
atomic_set(&ax25->refcount, 1);
|
||||
|
||||
skb_queue_head_init(&ax25->write_queue);
|
||||
|
Reference in New Issue
Block a user