#include <stdlib.h>
#include "flow.h"
#include "mac-learning.h"
+#include "odp-util.h"
#include "ofproto.h"
#include "rconn.h"
#include "status.h"
ofproto_add_flow(ofproto, flow, 0, UINT16_MAX, NULL, 0, NULL, -1);
} else if (out_port != FLOOD) {
/* The output port is known, so add a new flow. */
- action.output.port = htons(out_port);
+ action.output.port = htons(odp_port_to_ofp_port(out_port));
ofproto_add_flow(ofproto, flow, 0, UINT16_MAX,
&action, 1, payload, -1);
} else {
#include "flow.h"
#include "mac-learning.h"
#include "netdev.h"
+#include "odp-util.h"
#include "ofp-print.h"
#include "ofproto.h"
#include "ofpbuf.h"
ofproto_add_flow(ofproto, flow, 0, UINT16_MAX, NULL, 0, NULL, -1);
} else if (out_port != FLOOD) {
/* The output port is known, so add a new flow. */
- action.output.port = htons(out_port);
+ action.output.port = htons(odp_port_to_ofp_port(out_port));
ofproto_add_flow(ofproto, flow, 0, UINT16_MAX,
&action, 1, payload, -1);
} else {