aboutsummaryrefslogtreecommitdiff
path: root/ofproto/connmgr.h
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2013-10-22 16:16:31 -0700
committerBen Pfaff <blp@nicira.com>2013-10-22 21:12:06 -0700
commit0fb7792ab3428a28044e53b443388cbc1231035a (patch)
treef95d25509a5e4fd3dd00f91242cdae5927bdcfd0 /ofproto/connmgr.h
parent5b62d97786e4fea76aaa96ef0004465e8cb08cf8 (diff)
ofproto, ofp-util: Begin disentangling packet-in wire format and handling.
struct ofputil_packet_in mixes data included in OpenFlow packet_in messages with data that used internally by ofproto and connmgr to queue and route packet_ins. This commit begins disentangling these purposes by adding a new struct ofproto_packet_in that wraps struct ofputil_packet_in. Adding this new level of indirection causes a lot of code churn, so this commit mainly takes care of that to make the remaining changes easier to read. This commit does move the list node used for queuing packet_ins into the new wrapper structure. Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'ofproto/connmgr.h')
-rw-r--r--ofproto/connmgr.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/ofproto/connmgr.h b/ofproto/connmgr.h
index 505a757e..4846da9c 100644
--- a/ofproto/connmgr.h
+++ b/ofproto/connmgr.h
@@ -22,6 +22,7 @@
#include "list.h"
#include "match.h"
#include "ofp-errors.h"
+#include "ofp-util.h"
#include "ofproto.h"
#include "openflow/nicira-ext.h"
#include "openvswitch/types.h"
@@ -29,9 +30,6 @@
struct nlattr;
struct ofconn;
struct ofopgroup;
-struct ofputil_flow_removed;
-struct ofputil_packet_in;
-struct ofputil_phy_port;
struct rule;
struct simap;
struct sset;
@@ -64,6 +62,12 @@ enum ofconn_async_msg_type {
OAM_N_TYPES
};
+/* A packet_in, with extra members to assist in queuing and routing it. */
+struct ofproto_packet_in {
+ struct ofputil_packet_in up;
+ struct list list_node; /* For queuing. */
+};
+
/* Basics. */
struct connmgr *connmgr_create(struct ofproto *ofproto,
const char *dpif_name, const char *local_name);
@@ -141,7 +145,7 @@ void connmgr_send_port_status(struct connmgr *,
void connmgr_send_flow_removed(struct connmgr *,
const struct ofputil_flow_removed *);
void connmgr_send_packet_in(struct connmgr *,
- const struct ofputil_packet_in *);
+ const struct ofproto_packet_in *);
/* Fail-open settings. */
enum ofproto_fail_mode connmgr_get_fail_mode(const struct connmgr *);