}
/* Set time to live (TTL) of an MPLS label stack entry (LSE). */
-static void
+void
set_mpls_lse_ttl(ovs_be32 *lse, uint8_t ttl)
{
*lse &= ~htonl(MPLS_TTL_MASK);
len = (char*)packet->l2_5 - (char*)packet->l2;
/* If bottom of the stack set ethertype. */
if (mh->mpls_lse & htonl(MPLS_BOS_MASK)) {
- packet->l2_5 = NULL;
set_ethertype(packet, ethtype);
+ packet->l2_5 = NULL;
} else {
packet->l2_5 = (char*)packet->l2_5 + MPLS_HLEN;
}
uint8_t
packet_get_tcp_flags(const struct ofpbuf *packet, const struct flow *flow)
{
- if (is_ip_any(flow) && flow->nw_proto == IPPROTO_TCP && packet->l7) {
+ if (dl_type_is_ip_any(flow->dl_type) &&
+ flow->nw_proto == IPPROTO_TCP && packet->l7) {
const struct tcp_header *tcp = packet->l4;
return TCP_FLAGS(tcp->tcp_ctl);
} else {