aboutsummaryrefslogtreecommitdiff
path: root/lib/classifier.h
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2010-11-22 10:10:14 -0800
committerBen Pfaff <blp@nicira.com>2010-11-22 10:10:14 -0800
commit844dff325b1f6a6f520fce9242c85162275ab7ad (patch)
tree29f3140c56bee750f37b80890b8078cde7b8db08 /lib/classifier.h
parent0596e89755cea856d9615a46c17c4df2574107a3 (diff)
flow: Remove flow_to/from_match() in favor of cls_rule_to/from_match().
The flow_from_match() and flow_to_match() functions have to deal with most of the state in a cls_rule anyhow, and this will increase in upcoming commits, to the point that we might as well just use a cls_rule anyhow. This commit therefore deletes flow_from_match() and flow_to_match(), integrating their code into cls_rule_from_match() and the new function cls_rule_to_match(), respectively. It also changes each of the functions' callers to use the new cls_rule_*() function.
Diffstat (limited to 'lib/classifier.h')
-rw-r--r--lib/classifier.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/classifier.h b/lib/classifier.h
index ea4d6fc8..d8135e9e 100644
--- a/lib/classifier.h
+++ b/lib/classifier.h
@@ -70,9 +70,12 @@ void cls_rule_init(const struct flow *, const struct flow_wildcards *,
unsigned int priority, struct cls_rule *);
void cls_rule_init_exact(const struct flow *, unsigned int priority,
struct cls_rule *);
+void cls_rule_init_catchall(struct cls_rule *, unsigned int priority);
+
void cls_rule_from_match(const struct ofp_match *, unsigned int priority,
int flow_format, uint64_t cookie, struct cls_rule *);
-void cls_rule_init_catchall(struct cls_rule *, unsigned int priority);
+void cls_rule_to_match(const struct cls_rule *, int flow_format,
+ struct ofp_match *);
void cls_rule_zero_wildcarded_fields(struct cls_rule *);