提交 268a351d 编写于 作者: V Vlad Buslov 提交者: David S. Miller

net: sched: fix typo in walker_check_empty()

Function walker_check_empty() incorrectly verifies that tp pointer is not
NULL, instead of actual filter pointer. Fix conditional to check the right
pointer. Adjust filter pointer naming accordingly to other cls API
functions.

Fixes: 6676d5e4 ("net: sched: set dedicated tcf_walker flag when tp is empty")
Signed-off-by: NVlad Buslov <vladbu@mellanox.com>
Reported-by: NCong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 24ed4900
......@@ -238,10 +238,10 @@ static void tcf_proto_put(struct tcf_proto *tp, bool rtnl_held,
tcf_proto_destroy(tp, rtnl_held, extack);
}
static int walker_check_empty(struct tcf_proto *tp, void *d,
static int walker_check_empty(struct tcf_proto *tp, void *fh,
struct tcf_walker *arg)
{
if (tp) {
if (fh) {
arg->nonempty = true;
return -1;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册