From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58]) by dpdk.org (Postfix) with ESMTP id 7506AC326 for ; Thu, 4 Jun 2015 15:05:23 +0200 (CEST) Received: from hmsreliant.think-freely.org ([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost) by smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1Z0Upg-0003XV-0r; Thu, 04 Jun 2015 09:05:22 -0400 Date: Thu, 4 Jun 2015 09:05:10 -0400 From: Neil Horman To: Helin Zhang Message-ID: <20150604130510.GB24585@hmsreliant.think-freely.org> References: <1433379638-32715-1-git-send-email-helin.zhang@intel.com> <1433379638-32715-2-git-send-email-helin.zhang@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1433379638-32715-2-git-send-email-helin.zhang@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Score: -2.9 (--) X-Spam-Status: No Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH 1/6] ethdev: add an field for querying hash key size X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Jun 2015 13:05:23 -0000 On Thu, Jun 04, 2015 at 09:00:33AM +0800, Helin Zhang wrote: > To support querying hash key size per port, an new field of > 'hash_key_size' was added in 'struct rte_eth_dev_info' for storing > hash key size in bytes. > > Signed-off-by: Helin Zhang > --- > lib/librte_ether/rte_ethdev.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.h > index 16dbe00..004b05a 100644 > --- a/lib/librte_ether/rte_ethdev.h > +++ b/lib/librte_ether/rte_ethdev.h > @@ -916,6 +916,7 @@ struct rte_eth_dev_info { > uint16_t max_vmdq_pools; /**< Maximum number of VMDq pools. */ > uint32_t rx_offload_capa; /**< Device RX offload capabilities. */ > uint32_t tx_offload_capa; /**< Device TX offload capabilities. */ > + uint8_t hash_key_size; /**< Hash key size in bytes */ > uint16_t reta_size; > /**< Device redirection table size, the total number of entries. */ > /** Bit mask of RSS offloads, the bit offset also means flow type */ > -- > 1.9.3 > > You'll need to at least move this to the end of the structure to avoid ABI breakage, but even then, since the examples statically allocate this struct on the stack, you need to worry about previously compiled applications not having enough space allocated. Is there a hole in the struct that this can fit into to avoid changing the other member offsets? Neil