X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fofp-util.c;h=463248255da42d2c1e0b0c9f4c17b887e3f2c23d;hb=7c1b1a0d43cc20ed0ebc01cbcbcafb0ce6e3469c;hp=910e63a14a49e7a7c4ebdf5b141329fa5e0c3149;hpb=de0f3156a0ad6cc86b042d19ec8faf3c3a282ed5;p=sliver-openvswitch.git diff --git a/lib/ofp-util.c b/lib/ofp-util.c index 910e63a14..463248255 100644 --- a/lib/ofp-util.c +++ b/lib/ofp-util.c @@ -3073,7 +3073,21 @@ ofputil_encode_packet_out(const struct ofputil_packet_out *po, } case OFP11_VERSION: - case OFP12_VERSION: + case OFP12_VERSION: { + struct ofp11_packet_out *opo; + size_t len; + + msg = ofpraw_alloc(OFPRAW_OFPT11_PACKET_OUT, ofp_version, size); + ofpbuf_put_zeros(msg, sizeof *opo); + len = ofpacts_put_openflow11_actions(po->ofpacts, po->ofpacts_len, msg); + + opo = msg->l3; + opo->buffer_id = htonl(po->buffer_id); + opo->in_port = ofputil_port_to_ofp11(po->in_port); + opo->actions_len = htons(len); + break; + } + default: NOT_REACHED(); }