From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from proxy.6wind.com (host.76.145.23.62.rev.coltfrance.com [62.23.145.76]) by dpdk.org (Postfix) with ESMTP id 2A6185597 for ; Wed, 8 Mar 2017 10:42:24 +0100 (CET) Received: from glumotte.dev.6wind.com (unknown [10.16.0.195]) by proxy.6wind.com (Postfix) with ESMTP id 786B524D24; Wed, 8 Mar 2017 10:42:18 +0100 (CET) From: Olivier Matz To: dev@dpdk.org Cc: bruce.richardson@intel.com, konstantin.ananyev@intel.com, mb@smartsharesystems.com, andrey.chilikin@intel.com, jblunck@infradead.org, nelio.laranjeiro@6wind.com, arybchenko@solarflare.com Date: Wed, 8 Mar 2017 10:42:01 +0100 Message-Id: <1488966121-22853-10-git-send-email-olivier.matz@6wind.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1488966121-22853-1-git-send-email-olivier.matz@6wind.com> References: <1485271173-13408-1-git-send-email-olivier.matz@6wind.com> <1488966121-22853-1-git-send-email-olivier.matz@6wind.com> Subject: [dpdk-dev] [PATCH 9/9] mbuf: reorder VLAN tci and buffer len fields X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 08 Mar 2017 09:42:24 -0000 Move the vlan_tci field near vlan_tci_outer and buf_len near data_len for more consistency. It opens the door for get/set of the 2 vlan tci at the same time. Suggested-by: Andrey Chilikin Signed-off-by: Olivier Matz --- lib/librte_mbuf/rte_mbuf.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h index fd97bd3..ada98d5 100644 --- a/lib/librte_mbuf/rte_mbuf.h +++ b/lib/librte_mbuf/rte_mbuf.h @@ -449,8 +449,7 @@ struct rte_mbuf { uint32_t pkt_len; /**< Total pkt len: sum of all segments. */ uint16_t data_len; /**< Amount of data in segment buffer. */ - /** VLAN TCI (CPU order), valid if PKT_RX_VLAN_STRIPPED is set. */ - uint16_t vlan_tci; + uint16_t buf_len; /**< Size of segment buffer. */ union { uint32_t rss; /**< RSS hash result if RSS enabled */ @@ -475,11 +474,11 @@ struct rte_mbuf { uint32_t usr; /**< User defined tags. See rte_distributor_process() */ } hash; /**< hash information */ + /** VLAN TCI (CPU order), valid if PKT_RX_VLAN_STRIPPED is set. */ + uint16_t vlan_tci; /** Outer VLAN TCI (CPU order), valid if PKT_RX_QINQ_STRIPPED is set. */ uint16_t vlan_tci_outer; - uint16_t buf_len; /**< Length of segment buffer. */ - /** Valid if PKT_RX_TIMESTAMP is set. The unit and time reference * are not normalized but are always the same for a given port. */ -- 2.8.1