diff options
Diffstat (limited to 'src/pal/common/common_mbuf.h')
-rw-r--r-- | src/pal/common/common_mbuf.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/pal/common/common_mbuf.h b/src/pal/common/common_mbuf.h index c52842bd..3816d203 100644 --- a/src/pal/common/common_mbuf.h +++ b/src/pal/common/common_mbuf.h @@ -17,6 +17,12 @@ See the License for the specific language governing permissions and limitations under the License. */ +static inline void add_vlan(rte_mbuf_t *m, uint16_t vlan_id) { + m->ol_flags = PKT_TX_VLAN_PKT; + m->l2_len = 14; + m->vlan_tci = vlan_id; +} + static inline rte_mbuf_t * utl_rte_pktmbuf_add_after2(rte_mbuf_t *m1,rte_mbuf_t *m2){ utl_rte_pktmbuf_check(m1); utl_rte_pktmbuf_check(m2); |