net: sched: introduce block mechanism to handle netif_keep_dst calls
Couple of classifiers call netif_keep_dst directly on q->dev. That is not possible to do directly for shared blocke where multiple qdiscs are owning the block. So introduce a infrastructure to keep track of the block owners in list and use this list to implement block variant of netif_keep_dst. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Acked-by: Jamal Hadi Salim <jhs@mojatatu.com> Acked-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
9d3aaff3d8
commit
f36fe1c498
@@ -392,8 +392,8 @@ static int cls_bpf_prog_from_efd(struct nlattr **tb, struct cls_bpf_prog *prog,
|
||||
prog->bpf_name = name;
|
||||
prog->filter = fp;
|
||||
|
||||
if (fp->dst_needed && !(tp->q->flags & TCQ_F_INGRESS))
|
||||
netif_keep_dst(qdisc_dev(tp->q));
|
||||
if (fp->dst_needed)
|
||||
tcf_block_netif_keep_dst(tp->chain->block);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user