From: Yerden Zhumabekov Subject: Re: [PATCH 03/13] mbuf: add packet_type field Date: Mon, 8 Sep 2014 16:33:04 +0600 Message-ID: <540D85E0.4030203@sts.kz> References: <1409759378-10113-1-git-send-email-bruce.richardson@intel.com> <1409759378-10113-4-git-send-email-bruce.richardson@intel.com> <540D8228.809@6wind.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable To: Olivier MATZ , Bruce Richardson , Return-path: In-Reply-To: <540D8228.809-pdR9zngts4EAvxtiuMwx3w@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" I would use it :) It's useful to store the IP protocol number (UDP, TCP etc) and version of IP (4, 6) and then relay packet to specific handler. 08.09.2014 16:17, Olivier MATZ =D0=BF=D0=B8=D1=88=D0=B5=D1=82: > Hi Bruce, > > On 09/03/2014 05:49 PM, Bruce Richardson wrote: >> Replace a reserved slot with the new packet type field used to identif= y >> the type of the packet, i.e. what protocols are used. >> >> Signed-off-by: Bruce Richardson >> --- >> lib/librte_mbuf/rte_mbuf.h | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/lib/librte_mbuf/rte_mbuf.h b/lib/librte_mbuf/rte_mbuf.h >> index f136d37..8d0c6fb 100644 >> --- a/lib/librte_mbuf/rte_mbuf.h >> +++ b/lib/librte_mbuf/rte_mbuf.h >> @@ -146,7 +146,7 @@ struct rte_mbuf { >> uint32_t reserved1; /**< Unused field. Required for padding */ >> =20 >> /* remaining bytes are set on RX when pulling packet from descriptor= */ >> - uint16_t reserved2; /**< Unused field. Required for padding */ >> + uint16_t packet_type; /**< Type of packet, e.g. protocols used */ >> uint16_t data_len; /**< Amount of data in segment buffer. */ >> uint32_t pkt_len; /**< Total pkt len: sum of all segments. */ >> uint16_t l3_len:9; /**< L3 (IP) Header Length. */ >> > This patch adds a new fields that nobody uses. So why should we add it = ? --=20 Sincerely, Yerden Zhumabekov State Technical Service Astana, KZ