aboutsummaryrefslogtreecommitdiff
path: root/lib/dpif-netdev.c
diff options
context:
space:
mode:
authorAndy Zhou <azhou@nicira.com>2013-06-19 07:15:10 +0000
committerBen Pfaff <blp@nicira.com>2013-06-20 10:33:51 -0700
commite6cc0babc25de1800aeffad66d2804e64e5bd602 (patch)
tree72cc541897276ff2d6a656c65156caf82a55677d /lib/dpif-netdev.c
parenta1c564be1e2ffc31f8da09ab654c8ed987907fe5 (diff)
ovs-dpctl: Add mega flow support
Added support to allow mega flow specified and displayed. ovs-dpctl tool is mainly used as debugging tool. This patch also implements the low level user space routines to send and receive mega flow netlink messages. Those netlink suppor routines are required for forthcoming user space mega flow patches. Added a unit test to test parsing and display of mega flows. Ethan contributed the ovs-dpctl mega flow output function. Co-authored-by: Ethan Jackson <ethan@nicira.com> Signed-off-by: Ethan Jackson <ethan@nicira.com> Signed-off-by: Andy Zhou <azhou@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'lib/dpif-netdev.c')
-rw-r--r--lib/dpif-netdev.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
index 52aedb69..5a54627e 100644
--- a/lib/dpif-netdev.c
+++ b/lib/dpif-netdev.c
@@ -879,6 +879,7 @@ dpif_netdev_flow_dump_start(const struct dpif *dpif OVS_UNUSED, void **statep)
static int
dpif_netdev_flow_dump_next(const struct dpif *dpif, void *state_,
const struct nlattr **key, size_t *key_len,
+ const struct nlattr **mask, size_t *mask_len,
const struct nlattr **actions, size_t *actions_len,
const struct dpif_flow_stats **stats)
{
@@ -904,6 +905,11 @@ dpif_netdev_flow_dump_next(const struct dpif *dpif, void *state_,
*key_len = buf.size;
}
+ if (mask) {
+ *mask = NULL;
+ *mask_len = 0;
+ }
+
if (actions) {
free(state->actions);
state->actions = xmemdup(flow->actions, flow->actions_len);