The ethertype should be set before resetting l2_5 in order for the packet to be updated correctly.
Signed-off-by: Simon Horman <ho...@verge.net.au> --- v1.18 * First post --- lib/packets.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/packets.c b/lib/packets.c index 4f57d16..424f7ac 100644 --- a/lib/packets.c +++ b/lib/packets.c @@ -375,8 +375,8 @@ pop_mpls(struct ofpbuf *packet, ovs_be16 ethtype) 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; } -- 1.7.10.4 _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev