2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-17 14:28:02 +00:00

classifier: Introduce macros for iterating exact-match flows.

This special case of iterating through flows is easier and presumably
faster to implement using a macro.
This commit is contained in:
Ben Pfaff
2010-10-07 10:36:02 -07:00
parent da89bf9eb7
commit 35950f0cfa
3 changed files with 16 additions and 13 deletions

View File

@@ -168,4 +168,10 @@ struct cls_rule *classifier_find_rule_exactly(const struct classifier *,
uint32_t wildcards,
unsigned int priority);
#define CLASSIFIER_FOR_EACH_EXACT_RULE(RULE, MEMBER, CLS) \
HMAP_FOR_EACH (RULE, MEMBER.node.hmap, &(CLS)->exact_table)
#define CLASSIFIER_FOR_EACH_EXACT_RULE_SAFE(RULE, NEXT, CLS) \
HMAP_FOR_EACH_SAFE (RULE, NEXT, MEMBER.node.hmap, &(CLS)->exact_table)
#endif /* classifier.h */