From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <thomas.monjalon@6wind.com>
Received: from mail-wg0-f41.google.com (mail-wg0-f41.google.com [74.125.82.41])
 by dpdk.org (Postfix) with ESMTP id D1C3F2E89
 for <dev@dpdk.org>; Thu,  6 Nov 2014 09:24:17 +0100 (CET)
Received: by mail-wg0-f41.google.com with SMTP id k14so580396wgh.14
 for <dev@dpdk.org>; Thu, 06 Nov 2014 00:33:44 -0800 (PST)
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20130820;
 h=x-gm-message-state:from:to:cc:subject:date:message-id:organization
 :user-agent:in-reply-to:references:mime-version
 :content-transfer-encoding:content-type;
 bh=gKEcKdyeFTigTXP1ryaeJlkNFJ1fe6bQ9HUr4/+g66o=;
 b=b/7wyxm5Ag6NDUxkf5Xg6swd/JBUXZdbsZamI81jZlZg9kEXx5beYZ5najW7twD7Xv
 2L7wpPQzeB2A57LK90350j1+OBprWFgS0tp2f5WxtzNiZmwa2IMQBzos8bZvSboaPGA3
 f7NxltBqBtpH1MZpIM569RuVf+cQlme9sSt5b8BbzKIks5cRInE97BLbmXXwHuZC6rjw
 jg+0fCUFx0k18Su6FPpkxmKJRabaS7G9r7Lx2axfxL10CjzINu1n/IRxExJmsS0bGblB
 BWj6VSt9l7Bi00QwFlkY/Ki536XWipe06DO946yYHr7V77q9y5eh6TpZ3LlRU+iABnRS
 lm+g==
X-Gm-Message-State: ALoCoQmPKjKNVxVBeTJQU5YbdG+uuDiDRUz05LXOkKgIowCfl4F3G2NfBlEGyXvW0OhcqD4btJJV
X-Received: by 10.180.84.167 with SMTP id a7mr12251136wiz.39.1415262824393;
 Thu, 06 Nov 2014 00:33:44 -0800 (PST)
Received: from xps13.localnet (136-92-190-109.dsl.ovh.fr. [109.190.92.136])
 by mx.google.com with ESMTPSA id s8sm6921480wjx.9.2014.11.06.00.33.42
 for <multiple recipients>
 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Thu, 06 Nov 2014 00:33:43 -0800 (PST)
From: Thomas Monjalon <thomas.monjalon@6wind.com>
To: "Zhang, Helin" <helin.zhang@intel.com>
Date: Thu, 06 Nov 2014 09:33:24 +0100
Message-ID: <3931991.XHvGI58gnD@xps13>
Organization: 6WIND
User-Agent: KMail/4.14.2 (Linux/3.17.2-1-ARCH; KDE/4.14.2; x86_64; ; )
In-Reply-To: <F35DEAC7BCE34641BA9FAC6BCA4A12E70A7AF0BC@SHSMSX104.ccr.corp.intel.com>
References: <1413978810-24610-1-git-send-email-helin.zhang@intel.com>
 <3547625.yeCIkN20CJ@xps13>
 <F35DEAC7BCE34641BA9FAC6BCA4A12E70A7AF0BC@SHSMSX104.ccr.corp.intel.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 7Bit
Content-Type: text/plain; charset="us-ascii"
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v4 7/8] ethdev: support of multiple sizes of
	redirection table
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: patches and discussions about DPDK <dev.dpdk.org>
List-Unsubscribe: <http://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <http://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 06 Nov 2014 08:24:18 -0000

2014-11-06 01:02, Zhang, Helin:
> From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com]
> > 2014-10-31 17:03, Helin Zhang:
> > >  #define ETH_RSS_RETA_SIZE_64  64
> > >  #define ETH_RSS_RETA_SIZE_128 128
> > >  #define ETH_RSS_RETA_SIZE_512 512
> > 
> > Are these values still needed?
> 
> It was widely used in igb/ixgbe/i40e code, and app/testpmd. It is good to be kept there,
> though we can define them separately in each component. This would be more convenient
> for PMDs and user applications.

If it should be used by applications, it must stay in ethdev.

> > Why 256 is forbidden?
> 
> 256 is not a valid table size of current supported NICs, for other/future NIC which supports
> this size, it can be added later as needed.

The problem is that we don't know which value is supported for each driver.
You should add a comment like this:
/**@{
 * Some RSS RETA sizes may be not supported by some drivers.
 * Check in the PMD documentation.
 */
#define ETH_RSS_RETA_SIZE_64  64
#define ETH_RSS_RETA_SIZE_128 128
#define ETH_RSS_RETA_SIZE_512 512
/**@}*/

And then add some comments in the PMD to describe the supported sizes.

> > Maybe that some comments are needed here.
> 
> Comments might not be needed, as their names tell us what they are clearly. Did you mean
> any other annotations to be added for these macros? I am open for that to add any good
> annotations for them.

We just have to keep in mind that the API reference for users is in doxygen.
Some details are obvious for you but not clear for the user, especially if he
doesn't care about i40e.

Thanks
-- 
Thomas