sch_choke: Use kvcalloc
Convert the use of kvmalloc_array with __GFP_ZERO to the equivalent kvcalloc. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
f6f7d8cf55
commit
793da4bfba
@ -377,7 +377,7 @@ static int choke_change(struct Qdisc *sch, struct nlattr *opt,
|
|||||||
if (mask != q->tab_mask) {
|
if (mask != q->tab_mask) {
|
||||||
struct sk_buff **ntab;
|
struct sk_buff **ntab;
|
||||||
|
|
||||||
ntab = kvmalloc_array((mask + 1), sizeof(struct sk_buff *), GFP_KERNEL | __GFP_ZERO);
|
ntab = kvcalloc(mask + 1, sizeof(struct sk_buff *), GFP_KERNEL);
|
||||||
if (!ntab)
|
if (!ntab)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user