mbuf: switch vlan_tci and reserved2 fields
[dpdk.git] / lib / librte_mbuf / rte_mbuf.h
index 8e27d2e..68304cc 100644 (file)
@@ -159,8 +159,8 @@ struct rte_mbuf {
        uint16_t reserved2;       /**< Unused field. Required for padding */
        uint16_t data_len;        /**< Amount of data in segment buffer. */
        uint32_t pkt_len;         /**< Total pkt len: sum of all segments. */
-       uint16_t reserved;
        uint16_t vlan_tci;        /**< VLAN Tag Control Identifier (CPU order) */
+       uint16_t reserved;
        union {
                uint32_t rss;     /**< RSS hash result if RSS enabled */
                struct {
@@ -172,6 +172,12 @@ struct rte_mbuf {
 
        /* second cache line - fields only used in slow path or on TX */
        MARKER cacheline1 __rte_cache_aligned;
+
+       union {
+               void *userdata;   /**< Can be used for external metadata */
+               uint64_t udata64; /**< Allow 8-byte userdata on 32-bit */
+       };
+
        struct rte_mempool *pool; /**< Pool from which mbuf was allocated. */
        struct rte_mbuf *next;    /**< Next segment of scattered packet. */