DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Su, Simei" <simei.su@intel.com>
To: Andrew Rybchenko <arybchenko@solarflare.com>,
	Shahaf Shuler <shahafs@mellanox.com>,
	Adrien Mazarguil <adrien.mazarguil@6wind.com>
Cc: "Zhang, Qi Z" <qi.z.zhang@intel.com>,
	"Wu, Jingjing" <jingjing.wu@intel.com>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: add symmetric toeplitz hash support
Date: Mon, 30 Sep 2019 06:34:16 +0000	[thread overview]
Message-ID: <65F28F834D25B54B9EC1999B623071B30C45F70E@SHSMSX104.ccr.corp.intel.com> (raw)
In-Reply-To: <686e301d-8296-75dc-a132-389ba587f183@solarflare.com>

Hi, Andrew

> -----Original Message-----
> From: Andrew Rybchenko [mailto:arybchenko@solarflare.com]
> Sent: Monday, September 30, 2019 2:15 PM
> To: Su, Simei <simei.su@intel.com>; Shahaf Shuler <shahafs@mellanox.com>;
> Adrien Mazarguil <adrien.mazarguil@6wind.com>
> Cc: Zhang, Qi Z <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>;
> dev@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: add symmetric toeplitz hash
> support
> 
> Hi Simei,
> 
> On 9/30/19 6:12 AM, Su, Simei wrote:
> > Hi, Andrew
> >
> >> -----Original Message-----
> >> From: Andrew Rybchenko [mailto:arybchenko@solarflare.com]
> >> Sent: Sunday, September 29, 2019 7:51 PM
> >> To: Shahaf Shuler <shahafs@mellanox.com>; Adrien Mazarguil
> >> <adrien.mazarguil@6wind.com>
> >> Cc: Su, Simei <simei.su@intel.com>; Zhang, Qi Z
> >> <qi.z.zhang@intel.com>; Wu, Jingjing <jingjing.wu@intel.com>;
> >> dev@dpdk.org
> >> Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: add symmetric toeplitz
> >> hash support
> >>
> >> On 7/31/19 4:43 PM, Shahaf Shuler wrote:
> >>> Wednesday, July 31, 2019 3:31 PM, Adrien Mazarguil:
> >>>> Subject: Re: [dpdk-dev] [PATCH 1/2] ethdev: add symmetric toeplitz
> >>>> hash support
> >>>>
> >>>> On Wed, Jul 31, 2019 at 03:08:19PM +0300, Andrew Rybchenko wrote:
> >>>>> On 7/25/19 7:57 AM, simei wrote:
> >>>>>> From: Simei Su <simei.su@intel.com>
> >>>>>>
> >>>>>> Currently, there are DEFAULT,TOEPLITZ and SIMPLE_XOR hash funtion.
> >>>>>> To support symmetric hash by rte_flow RSS action, this patch adds
> >>>>>> new hash function "Symmetric Toeplitz" which is supported by some
> >>>> hardware.
> >>>>> Isn't it a question of key to achieve symmetry?
> >>>>> I.e. hash algorithm (function) is still the same - Toeplitz, but
> >>>>> hash key makes the result symmetric (i.e. equal for flows in both
> >>>>> directions - swap transport ports and IPv4/6 addresses).
> >>>> This is only an option when src/dst are known in advance.
> >>>>
> >>>> When doing RSS, HW implementations (such as Mellanox's) implement a
> >>>> modified Toeplitz XOR'ing src with dst resulting in the same hash
> >>>> both ways regardless of the key.
> >>> Just to stand correct it was a bug on Mellanox kernel driver that
> >>> was fixed. Now
> >> the RSS is spec complaint (non-symmetric).
> >>> Andrew is correct one can have a special key that will make the RSS
> >>> symmetric,
> >> however it is good to have this option for the user to explicitly
> >> request symmetric function (w/o any restriction on the key).
> >>
> >> I think we need a definition what is behind SYMMETRIC_TOEPLITZ here.
> >> If I'd like to test it and check, I need to know an algorithm in
> >> order to know what to expect.
> >> Also it is important to make it the same for all NIC vendors: what
> >> should algorithm be in order to say that it is symmetric Toeplitz?
> > The symmetric toeplitz is: src, dst will be replaced by xor(src, dst).
> > It is expected to get the same hash value when swapping src/dst ip or port.
> 
> Are both replaced by XOR or just one is replaced by XOR and another one
> removed from Toeplitz input? If later, how does it coexist with src/dst only flags?
> 
> Anyway, please, add it to the patch in Doxygen comments.
> 
  In our case, src and dst are both replaced by XOR. For example, src ip and dst ip or src port and dst port are swapped, the hash value is the same.
  SRC/DST only flags is another thing, it covers input set change.

Br
Simei

> Thanks,
> Andrew.

  reply	other threads:[~2019-09-30  6:34 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-25  4:57 [dpdk-dev] [PATCH 0/2] " simei
2019-07-25  4:57 ` [dpdk-dev] [PATCH 1/2] ethdev: " simei
2019-07-31 12:08   ` Andrew Rybchenko
2019-07-31 12:30     ` Adrien Mazarguil
2019-07-31 13:03       ` Andrew Rybchenko
2019-07-31 13:43       ` Shahaf Shuler
2019-09-29 11:51         ` Andrew Rybchenko
2019-09-30  3:12           ` Su, Simei
2019-09-30  6:14             ` Andrew Rybchenko
2019-09-30  6:34               ` Su, Simei [this message]
2019-09-30  7:49                 ` Zhang, Qi Z
2019-07-25  4:57 ` [dpdk-dev] [PATCH 2/2] app/testpmd: " simei
2019-07-26  0:55 ` [dpdk-dev] [PATCH v2 0/2] " simei
2019-07-26  0:55   ` [dpdk-dev] [PATCH v2 1/2] ethdev: " simei
2019-09-28 18:32     ` Ori Kam
2019-07-26  0:55   ` [dpdk-dev] [PATCH v2 2/2] app/testpmd: " simei
2019-09-28 18:39     ` Ori Kam
2019-09-24  5:30   ` [dpdk-dev] [PATCH v2 0/2] " Zhang, Qi Z
2019-10-01  9:22   ` [dpdk-dev] [PATCH v3 " Simei Su
2019-10-01  9:22     ` [dpdk-dev] [PATCH v3 1/2] ethdev: " Simei Su
2019-10-01 13:36       ` Andrew Rybchenko
2019-10-01  9:22     ` [dpdk-dev] [PATCH v3 2/2] app/testpmd: " Simei Su
2019-10-01 15:06     ` [dpdk-dev] [PATCH v3 0/2] " Ferruh Yigit
2019-09-23 23:11 ` [dpdk-dev] [PATCH " Zhang, Qi Z

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=65F28F834D25B54B9EC1999B623071B30C45F70E@SHSMSX104.ccr.corp.intel.com \
    --to=simei.su@intel.com \
    --cc=adrien.mazarguil@6wind.com \
    --cc=arybchenko@solarflare.com \
    --cc=dev@dpdk.org \
    --cc=jingjing.wu@intel.com \
    --cc=qi.z.zhang@intel.com \
    --cc=shahafs@mellanox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).