lib/ofp-protocol.c
/* Returns an NXT_SET_FLOW_FORMAT message that can be used to set the flow
 * format to 'protocol'.  */
Returns an NXT_SET_FLOW_FORMAT message that can be used to set the flow
format to 'protocol'.
Returns an NXT_SET_FLOW_FORMAT message that can be used to set the flow format to ' protocol ' .
struct ofpbuf *
ofputil_encode_nx_set_flow_format(enum ofputil_protocol protocol)
{
    struct ofpbuf *msg = ofpraw_alloc(OFPRAW_NXT_SET_FLOW_FORMAT,
                                      OFP10_VERSION, 0);
    ovs_be32 *nxff = ofpbuf_put_uninit(msg, sizeof *nxff);
    if (protocol == OFPUTIL_P_OF10_STD) {
        *nxff = htonl(NXFF_OPENFLOW10);
    } else if (protocol == OFPUTIL_P_OF10_NXM) {
        *nxff = htonl(NXFF_NXM);
    } else {
        OVS_NOT_REACHED();
    }
    return msg;
}
struct ofpbuf * ofputil_encode_nx_set_flow_format ( enum ofputil_protocol protocol ) { struct ofpbuf * msg = ofpraw_alloc ( OFPRAW_NXT_SET_FLOW_FORMAT , OFP10_VERSION , 0 ) ; ovs_be32 * nxff = ofpbuf_put_uninit ( msg , sizeof * nxff ) ; if ( protocol == OFPUTIL_P_OF10_STD ) { * nxff = htonl ( NXFF_OPENFLOW10 ) ; } else if ( protocol == OFPUTIL_P_OF10_NXM ) { * nxff = htonl ( NXFF_NXM ) ; } else { OVS_NOT_REACHED ( ) ; } return msg ; }
Returns an NXT_SET_FLOW_FORMAT message that can be used to set the flow
 format to 'protocol'.
Returns an NXT_SET_FLOW_FORMAT message that can be used to set the flow format to ' protocol ' .