From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.droids-corp.org (zoll.droids-corp.org [94.23.50.67]) by dpdk.org (Postfix) with ESMTP id E5DAF2951 for ; Tue, 16 Jan 2018 11:42:47 +0100 (CET) Received: from lfbn-lil-1-110-231.w90-45.abo.wanadoo.fr ([90.45.197.231] helo=droids-corp.org) by mail.droids-corp.org with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1ebOhX-0008Cn-Q2; Tue, 16 Jan 2018 11:42:45 +0100 Received: by droids-corp.org (sSMTP sendmail emulation); Tue, 16 Jan 2018 11:42:38 +0100 Date: Tue, 16 Jan 2018 11:42:38 +0100 From: Olivier Matz To: "Wang, Xiao W" Cc: "yliu@fridaylinux.org" , "thomas@monjalon.net" , "Bie, Tiwei" , "dev@dpdk.org" , "stephen@networkplumber.org" , "maxime.coquelin@redhat.com" Message-ID: <20180116104238.n4uzmby46zlyogjn@platinum> References: <20180109160918.29173-4-xiao.w.wang@intel.com> <20180110012356.57456-1-xiao.w.wang@intel.com> <20180110012356.57456-4-xiao.w.wang@intel.com> <20180116090122.fsvqrgzu5rjqcgre@platinum> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Subject: Re: [dpdk-dev] [PATCH v10 3/5] net: add a helper for making RARP packet 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: Tue, 16 Jan 2018 10:42:48 -0000 Hi Xiao, On Tue, Jan 16, 2018 at 09:43:43AM +0000, Wang, Xiao W wrote: > Hi Olivier, > > You can also use rte_pktmbuf_append() to check for the tailroom and > > update data_len/pkt_len: > > > > m = rte_pktmbuf_alloc(); > > if (m == NULL) > > return NULL; > > eth_hdr = rte_pktmbuf_append(m, RARP_PKT_SIZE); > > When data_len is not enough, we need to rte_pktmbuf_append(m, RARP_PKT_SIZE - m->data_len); Sorry, I don't get your point here.