From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 1DBC05A9A for ; Thu, 4 Jun 2015 12:38:11 +0200 (CEST) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by fmsmga103.fm.intel.com with ESMTP; 04 Jun 2015 03:38:10 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.13,552,1427785200"; d="scan'208";a="705205797" Received: from irsmsx151.ger.corp.intel.com ([163.33.192.59]) by orsmga001.jf.intel.com with ESMTP; 04 Jun 2015 03:38:10 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.73]) by IRSMSX151.ger.corp.intel.com ([169.254.4.102]) with mapi id 14.03.0224.002; Thu, 4 Jun 2015 11:38:09 +0100 From: "Ananyev, Konstantin" To: "Zhang, Helin" , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v2 1/6] ethdev: add an field for querying hash key size Thread-Index: AQHQnpjigkYRaMPWQUioxfC5T0983p2cJc5A Date: Thu, 4 Jun 2015 10:38:08 +0000 Message-ID: <2601191342CEEE43887BDE71AB97725821434EFF@irsmsx105.ger.corp.intel.com> References: <1433379638-32715-1-git-send-email-helin.zhang@intel.com> <1433403216-7114-1-git-send-email-helin.zhang@intel.com> <1433403216-7114-2-git-send-email-helin.zhang@intel.com> In-Reply-To: <1433403216-7114-2-git-send-email-helin.zhang@intel.com> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.181] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v2 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 10:38:12 -0000 Hi Helin, > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Helin Zhang > Sent: Thursday, June 04, 2015 8:34 AM > To: dev@dpdk.org > Subject: [dpdk-dev] [PATCH v2 1/6] ethdev: add an field for querying hash= key size >=20 > 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. >=20 > Signed-off-by: Helin Zhang > --- > lib/librte_ether/rte_ethdev.h | 3 +++ > 1 file changed, 3 insertions(+) >=20 > v2 changes: > * Disabled the code changes by default, to avoid breaking ABI compatibili= ty. >=20 > diff --git a/lib/librte_ether/rte_ethdev.h b/lib/librte_ether/rte_ethdev.= h > index 16dbe00..bdebc87 100644 > --- a/lib/librte_ether/rte_ethdev.h > +++ b/lib/librte_ether/rte_ethdev.h > @@ -916,6 +916,9 @@ 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. */ > +#ifdef RTE_QUERY_HASH_KEY_SIZE > + uint8_t hash_key_size; /**< Hash key size in bytes */ > +#endif > 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 */ Why do you need to introduce an #ifdef RTE_QUERY_HASH_KEY_SIZE around your code? Why not to have it always on? Is it because of not breaking ABI for 2.1? But here, I suppose there would be no breakage anyway: struct rte_eth_dev_info { ... uint32_t tx_offload_capa; /**< Device TX offload capabilities. */ 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 *= / uint64_t flow_type_rss_offloads; struct rte_eth_rxconf default_rxconf; =20 so between 'reta_size' and 'flow_type_rss_offloads', there is a 2 bytes gap= . Wonder, why not put it there? Konstantin > -- > 1.9.3