Thread (44 messages) 44 messages, 6 authors, 2018-11-21

[PATCH net-next,v2 07/12] cls_flower: don't expose TC actions to drivers anymore

STALE2871d

From: Pablo Neira Ayuso <pablo@netfilter.org>
Date: 2018-11-19 10:39:09
Subsystem: networking [general], tc subsystem, the rest · Maintainers: "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Jamal Hadi Salim, Jiri Pirko, Linus Torvalds

Revision v2 of 8 in this series.

Revisions (8)
  1. rfc [diff vs current]
  2. v1 [diff vs current]
  3. v2 current
  4. v3 [diff vs current]
  5. v4 [diff vs current]
  6. v5 [diff vs current]
  7. v6 [diff vs current]
  8. v7 [diff vs current]
Now that drivers have been converted to use the flow action
infrastructure, remove this field from the tc_cls_flower_offload
structure.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
---
v2: no changes.

 include/net/pkt_cls.h  | 1 -
 net/sched/cls_flower.c | 5 -----
 2 files changed, 6 deletions(-)
diff --git a/include/net/pkt_cls.h b/include/net/pkt_cls.h
index 7f9a8d5ca945..fe64638034f8 100644
--- a/include/net/pkt_cls.h
+++ b/include/net/pkt_cls.h
@@ -769,7 +769,6 @@ struct tc_cls_flower_offload {
 	enum tc_fl_command command;
 	unsigned long cookie;
 	struct flow_rule rule;
-	struct tcf_exts *exts;
 	u32 classid;
 	struct tc_cls_flower_stats stats;
 };
diff --git a/net/sched/cls_flower.c b/net/sched/cls_flower.c
index ee67f1ae8786..440d475c55d0 100644
--- a/net/sched/cls_flower.c
+++ b/net/sched/cls_flower.c
@@ -389,7 +389,6 @@ static int fl_hw_replace_filter(struct tcf_proto *tp,
 	cls_flower.rule.match.dissector = &f->mask->dissector;
 	cls_flower.rule.match.mask = &f->mask->key;
 	cls_flower.rule.match.key = &f->mkey;
-	cls_flower.exts = &f->exts;
 	cls_flower.classid = f->res.classid;
 
 	if (tc_setup_flow_action(&f->action, &f->exts) < 0)
@@ -425,7 +424,6 @@ static void fl_hw_update_stats(struct tcf_proto *tp, struct cls_fl_filter *f)
 	tc_cls_common_offload_init(&cls_flower.common, tp, f->flags, NULL);
 	cls_flower.command = TC_CLSFLOWER_STATS;
 	cls_flower.cookie = (unsigned long) f;
-	cls_flower.exts = &f->exts;
 	cls_flower.classid = f->res.classid;
 
 	tc_setup_cb_call(block, &f->exts, TC_SETUP_CLSFLOWER,
@@ -1484,7 +1482,6 @@ static int fl_reoffload(struct tcf_proto *tp, bool add, tc_setup_cb_t *cb,
 			cls_flower.rule.match.dissector = &mask->dissector;
 			cls_flower.rule.match.mask = &mask->key;
 			cls_flower.rule.match.key = &f->mkey;
-			cls_flower.exts = &f->exts;
 			cls_flower.rule.action.num_keys = f->action.num_keys;
 			cls_flower.rule.action.keys = f->action.keys;
 			cls_flower.classid = f->res.classid;
@@ -1509,7 +1506,6 @@ static void fl_hw_create_tmplt(struct tcf_chain *chain,
 {
 	struct tc_cls_flower_offload cls_flower = {};
 	struct tcf_block *block = chain->block;
-	struct tcf_exts dummy_exts = { 0, };
 
 	cls_flower.common.chain_index = chain->index;
 	cls_flower.command = TC_CLSFLOWER_TMPLT_CREATE;
@@ -1517,7 +1513,6 @@ static void fl_hw_create_tmplt(struct tcf_chain *chain,
 	cls_flower.rule.match.dissector = &tmplt->dissector;
 	cls_flower.rule.match.mask = &tmplt->mask;
 	cls_flower.rule.match.key = &tmplt->dummy_key;
-	cls_flower.exts = &dummy_exts;
 
 	/* We don't care if driver (any of them) fails to handle this
 	 * call. It serves just as a hint for it.
-- 
2.11.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help