[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180717125814.13792-1-yuehaibing@huawei.com>
Date: Tue, 17 Jul 2018 20:58:14 +0800
From: YueHaibing <yuehaibing@...wei.com>
To: <davem@...emloft.net>, <jhs@...atatu.com>,
<xiyou.wangcong@...il.com>, <jiri@...nulli.us>
CC: <linux-kernel@...r.kernel.org>, <netdev@...r.kernel.org>,
YueHaibing <yuehaibing@...wei.com>
Subject: [PATCH net-next] net: sched: Using NULL instead of plain integer
Fixes the following sparse warnings:
net/sched/cls_api.c:1101:43: warning: Using plain integer as NULL pointer
net/sched/cls_api.c:1492:75: warning: Using plain integer as NULL pointer
Signed-off-by: YueHaibing <yuehaibing@...wei.com>
---
net/sched/cls_api.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/sched/cls_api.c b/net/sched/cls_api.c
index c51b1b1..623fe2c 100644
--- a/net/sched/cls_api.c
+++ b/net/sched/cls_api.c
@@ -1098,7 +1098,7 @@ static void tfilter_notify_chain(struct net *net, struct sk_buff *oskb,
for (tp = rtnl_dereference(chain->filter_chain);
tp; tp = rtnl_dereference(tp->next))
tfilter_notify(net, oskb, n, tp, block,
- q, parent, 0, event, false);
+ q, parent, NULL, event, false);
}
static int tc_new_tfilter(struct sk_buff *skb, struct nlmsghdr *n,
@@ -1489,7 +1489,7 @@ static bool tcf_chain_dump(struct tcf_chain *chain, struct Qdisc *q, u32 parent,
memset(&cb->args[1], 0,
sizeof(cb->args) - sizeof(cb->args[0]));
if (cb->args[1] == 0) {
- if (tcf_fill_node(net, skb, tp, block, q, parent, 0,
+ if (tcf_fill_node(net, skb, tp, block, q, parent, NULL,
NETLINK_CB(cb->skb).portid,
cb->nlh->nlmsg_seq, NLM_F_MULTI,
RTM_NEWTFILTER) <= 0)
--
2.7.0
Powered by blists - more mailing lists