datapath: Change listing flows to use an iterator concept.
[openvswitch] / datapath / odp-compat.h
index 5c9eb8158e44d22b099b75b09ae15838b9585120..ca2f17001d5f9d97ad37a1f36b046ab53ac11c74 100644 (file)
@@ -16,9 +16,9 @@
 #include <linux/compat.h>
 
 #define ODP_VPORT_LIST32       _IOWR('O', 10, struct compat_odp_portvec)
-#define ODP_FLOW_GET32         _IOWR('O', 13, struct compat_odp_flow)
+#define ODP_FLOW_GET32         _IOWR('O', 13, struct compat_odp_flowvec)
 #define ODP_FLOW_PUT32         _IOWR('O', 14, struct compat_odp_flow)
-#define ODP_FLOW_LIST32                _IOWR('O', 15, struct compat_odp_flowvec)
+#define ODP_FLOW_DUMP32                _IOWR('O', 15, struct compat_odp_flow_dump)
 #define ODP_FLOW_DEL32         _IOWR('O', 17, struct compat_odp_flow)
 #define ODP_EXECUTE32          _IOR('O', 18, struct compat_odp_execute)
 #define ODP_FLOW_DEL32         _IOWR('O', 17, struct compat_odp_flow)
@@ -32,7 +32,7 @@ struct compat_odp_flow {
        struct odp_flow_stats stats;
        struct odp_flow_key key;
        compat_uptr_t actions;
-       u32 n_actions;
+       u32 actions_len;
        u32 flags;
 };
 
@@ -41,6 +41,11 @@ struct compat_odp_flow_put {
        u32 flags;
 };
 
+struct compat_odp_flow_dump {
+       compat_uptr_t flow;
+       uint32_t state[2];
+};
+
 struct compat_odp_flowvec {
        compat_uptr_t flows;
        u32 n_flows;
@@ -48,7 +53,7 @@ struct compat_odp_flowvec {
 
 struct compat_odp_execute {
        compat_uptr_t actions;
-       u32 n_actions;
+       u32 actions_len;
 
        compat_uptr_t data;
        u32 length;