diff options
author | David S. Miller <davem@davemloft.net> | 2017-10-30 01:10:01 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-10-30 08:09:24 -0400 |
commit | e1ea2f9856b765a2eaabb403a6751f70efc9ba4c (patch) | |
tree | 771f0f96fdab1b27757730e96d911c73f5499ee4 /net/sched/cls_basic.c | |
parent | aad93c70b9a3b80dbc383a31e77a119f69bdd856 (diff) | |
parent | 0b07194bb55ed836c2cc7c22e866b87a14681984 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Several conflicts here.
NFP driver bug fix adding nfp_netdev_is_nfp_repr() check to
nfp_fl_output() needed some adjustments because the code block is in
an else block now.
Parallel additions to net/pkt_cls.h and net/sch_generic.h
A bug fix in __tcp_retransmit_skb() conflicted with some of
the rbtree changes in net-next.
The tc action RCU callback fixes in 'net' had some overlap with some
of the recent tcf_block reworking.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/cls_basic.c')
-rw-r--r-- | net/sched/cls_basic.c | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/net/sched/cls_basic.c b/net/sched/cls_basic.c index 700b345b07f9..871351358c10 100644 --- a/net/sched/cls_basic.c +++ b/net/sched/cls_basic.c | |||
@@ -35,7 +35,10 @@ struct basic_filter { | |||
35 | struct tcf_result res; | 35 | struct tcf_result res; |
36 | struct tcf_proto *tp; | 36 | struct tcf_proto *tp; |
37 | struct list_head link; | 37 | struct list_head link; |
38 | struct rcu_head rcu; | 38 | union { |
39 | struct work_struct work; | ||
40 | struct rcu_head rcu; | ||
41 | }; | ||
39 | }; | 42 | }; |
40 | 43 | ||
41 | static int basic_classify(struct sk_buff *skb, const struct tcf_proto *tp, | 44 | static int basic_classify(struct sk_buff *skb, const struct tcf_proto *tp, |
@@ -84,15 +87,26 @@ static int basic_init(struct tcf_proto *tp) | |||
84 | return 0; | 87 | return 0; |
85 | } | 88 | } |
86 | 89 | ||
87 | static void basic_delete_filter(struct rcu_head *head) | 90 | static void basic_delete_filter_work(struct work_struct *work) |
88 | { | 91 | { |
89 | struct basic_filter *f = container_of(head, struct basic_filter, rcu); | 92 | struct basic_filter *f = container_of(work, struct basic_filter, work); |
90 | 93 | ||
94 | rtnl_lock(); | ||
91 | tcf_exts_destroy(&f->exts); | 95 | tcf_exts_destroy(&f->exts); |
92 | tcf_em_tree_destroy(&f->ematches); | 96 | tcf_em_tree_destroy(&f->ematches); |
97 | rtnl_unlock(); | ||
98 | |||
93 | kfree(f); | 99 | kfree(f); |
94 | } | 100 | } |
95 | 101 | ||
102 | static void basic_delete_filter(struct rcu_head *head) | ||
103 | { | ||
104 | struct basic_filter *f = container_of(head, struct basic_filter, rcu); | ||
105 | |||
106 | INIT_WORK(&f->work, basic_delete_filter_work); | ||
107 | tcf_queue_work(&f->work); | ||
108 | } | ||
109 | |||
96 | static void basic_destroy(struct tcf_proto *tp) | 110 | static void basic_destroy(struct tcf_proto *tp) |
97 | { | 111 | { |
98 | struct basic_head *head = rtnl_dereference(tp->root); | 112 | struct basic_head *head = rtnl_dereference(tp->root); |