ofproto-dpif: Refresh stats before ovs-appctl dpif/dump-flows.
authorEthan Jackson <ethan@nicira.com>
Tue, 15 Jan 2013 02:02:27 +0000 (18:02 -0800)
committerEthan Jackson <ethan@nicira.com>
Thu, 24 Jan 2013 20:34:07 +0000 (12:34 -0800)
As a matter of convenience, this patch refreshes the statistics
when ovs-appctl dpif/dump-flows is called.  Hopefully this will
prevent users from being confused because statistics they were
expecting to see haven't made it from the datapath into the switch
yet.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
ofproto/ofproto-dpif.c

index d1e4faf..2f78267 100644 (file)
@@ -7636,6 +7636,8 @@ ofproto_unixctl_dpif_dump_flows(struct unixctl_conn *conn,
         return;
     }
 
+    update_stats(ofproto->backer);
+
     HMAP_FOR_EACH (subfacet, hmap_node, &ofproto->subfacets) {
         struct odputil_keybuf keybuf;
         struct ofpbuf key;