mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-18 03:44:27 +08:00
[IPV4] fib_trie: removes a memset() call in tnode_new()
tnode_alloc() already clears allocated memory, using kcalloc() or alloc_pages(GFP_KERNEL|__GFP_ZERO, ...) Signed-off-by: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
88ebc72f68
commit
4dde4610c4
@ -391,7 +391,6 @@ static struct tnode* tnode_new(t_key key, int pos, int bits)
|
|||||||
struct tnode *tn = tnode_alloc(sz);
|
struct tnode *tn = tnode_alloc(sz);
|
||||||
|
|
||||||
if (tn) {
|
if (tn) {
|
||||||
memset(tn, 0, sz);
|
|
||||||
tn->parent = T_TNODE;
|
tn->parent = T_TNODE;
|
||||||
tn->pos = pos;
|
tn->pos = pos;
|
||||||
tn->bits = bits;
|
tn->bits = bits;
|
||||||
|
Loading…
Reference in New Issue
Block a user