New upstream version 18.11.2
[deb_dpdk.git] / lib / librte_net / rte_ether.h
index bee2b34..e0d8311 100644 (file)
@@ -306,6 +306,8 @@ struct vxlan_hdr {
 #define ETHER_TYPE_SLOW 0x8809 /**< Slow protocols (LACP and Marker). */
 #define ETHER_TYPE_TEB  0x6558 /**< Transparent Ethernet Bridging. */
 #define ETHER_TYPE_LLDP 0x88CC /**< LLDP Protocol. */
+#define ETHER_TYPE_MPLS 0x8847 /**< MPLS ethertype. */
+#define ETHER_TYPE_MPLSM 0x8848 /**< MPLS multicast ethertype. */
 
 #define ETHER_VXLAN_HLEN (sizeof(struct udp_hdr) + sizeof(struct vxlan_hdr))
 /**< VXLAN tunnel header length. */
@@ -406,7 +408,7 @@ static inline int rte_vlan_insert(struct rte_mbuf **m)
        vh = (struct vlan_hdr *) (nh + 1);
        vh->vlan_tci = rte_cpu_to_be_16((*m)->vlan_tci);
 
-       (*m)->ol_flags &= ~PKT_RX_VLAN_STRIPPED;
+       (*m)->ol_flags &= ~(PKT_RX_VLAN_STRIPPED | PKT_TX_VLAN);
 
        return 0;
 }