- struct ofp_match match;
- struct cls_rule target;
- struct flow_stats_ds_cbdata cbdata;
-
- memset(&match, 0, sizeof match);
- match.wildcards = htonl(OVSFW_ALL);
-
- cbdata.ofproto = p;
- cbdata.results = results;
-
- cls_rule_from_match(&match, 0, NXFF_OPENFLOW10, 0, &target);
- classifier_for_each_match(&p->cls, &target, flow_stats_ds_cb, &cbdata);
-}
-
-struct aggregate_stats_cbdata {
- struct ofproto *ofproto;
- ovs_be16 out_port;
- uint64_t packet_count;
- uint64_t byte_count;
- uint32_t n_flows;
-};
-
-static void
-aggregate_stats_cb(struct cls_rule *rule_, void *cbdata_)
-{
- struct rule *rule = rule_from_cls_rule(rule_);
- struct aggregate_stats_cbdata *cbdata = cbdata_;
- uint64_t packet_count, byte_count;