From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id DCA55A0487 for ; Thu, 4 Jul 2019 11:07:22 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id AAE2B1B997; Thu, 4 Jul 2019 11:07:22 +0200 (CEST) Received: from mail-wr1-f43.google.com (mail-wr1-f43.google.com [209.85.221.43]) by dpdk.org (Postfix) with ESMTP id 86EAE4CA6 for ; Thu, 4 Jul 2019 11:07:21 +0200 (CEST) Received: by mail-wr1-f43.google.com with SMTP id z1so1121645wru.13 for ; Thu, 04 Jul 2019 02:07:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=DOa0BiwQK5dtnMoBSXWTw0cWntfPeclpzm1MPYeaDRk=; b=EmyqRFX6NnBVbAI3jpJx5uF86OL2wN+LR1dHNLNcKtaE+fdnkW2+r+V51gbKJ9QJag GdH6/BhfNDcmVushe3pEnU5BiVJXFYvgqhEGUKDa0G33Xk6F7ANUCdAoQCzSHh6NpFN6 z1tiDS0Qujt13kZ0lQZ1++OLFHoYxgCAaqos8BgNAiLr0dULErD4C8twb2ge7xJKQNTm wIZcNU9o0/+wHiEMa5t8SgNu8DpZiI5qH2nABbvguCs5OuJBcF/Whl4ohNoH8LEgNtNU 3Yw2s9vxYJ0/K/+35KCZmRpPuUEnTKlWjF8Lc06dun2TLv/ppuuz8T/EjGFctQNyLFnb jzbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=DOa0BiwQK5dtnMoBSXWTw0cWntfPeclpzm1MPYeaDRk=; b=I40Kt81Yo62dyjxJDc8L+dK9y5l/K4S5gxzWM4Tsw2J9dvgvMIeOkykPTwITeKKrfC h5M8ESB9KC7CIzbNRXBTSgJS4V/nwE4K40g/bpgAzKGM9fUPUl+7G6gar3fxsoYdMfaj 7WEXXofa0OGlpaF6fB64wGh4AxtgtvM0NNpTOWYZH0v9OJVtMpsmaCMKfS8vuKQ37q7E u5Vs9xlHY7kJYnqi0myX36eqBpctWsyqPtGdEvjOzuKRBgFeBQkTb56jQRUffpHv+w28 zn0DR12Omgn5rX4I5wkhxGi13nhm8+Qm1YYAvC55a+fm1a/2flFAP/xRgJJZZ4xiLwBI T3HA== X-Gm-Message-State: APjAAAXWA3/MSwkgxCKd7z2jR9AARiybWgvWeBEJN80H8QdYrjJMcNSw pgyrMrgqB1LGWZoBbon5HHHzFQ== X-Google-Smtp-Source: APXvYqwXeGLJjp5jHDUnTuetb8D/OZdOdbFPtPN4kC0h4ncWCe7T6O7AbN/ib8O5vbB+JuuCl3IL1A== X-Received: by 2002:adf:fa49:: with SMTP id y9mr24622243wrr.6.1562231241323; Thu, 04 Jul 2019 02:07:21 -0700 (PDT) Received: from 6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id e6sm5172362wrw.23.2019.07.04.02.07.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 04 Jul 2019 02:07:20 -0700 (PDT) Date: Thu, 4 Jul 2019 11:07:19 +0200 From: Adrien Mazarguil To: simei Cc: qi.z.zhang@intel.com, jingjing.wu@intel.com, beilei.xing@intel.com, qiming.yang@intel.com, dev@dpdk.org Message-ID: <20190704090719.GK4512@6wind.com> References: <1562215629-75520-1-git-send-email-simei.su@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1562215629-75520-1-git-send-email-simei.su@intel.com> Subject: Re: [dpdk-dev] [RFC] ethdev: support input set change by RSS action 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, Jul 04, 2019 at 12:47:09PM +0800, simei wrote: > From: Simei Su > > This RFC introduces inputset structure to rte_flow_action_rss to > support input set specific configuration by rte_flow RSS action. > > We can give an testpmd command line example to make it more clear. > > For example, below flow selects the l4 port as inputset for any > eth/ipv4/tcp packet: #flow create 0 ingress pattern eth / ipv4 / tcp / > end actions rss inputset tcp src mask 0xffff dst mask 0xffff /end > > Signed-off-by: Simei Su > --- > lib/librte_ethdev/rte_flow.h | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/lib/librte_ethdev/rte_flow.h b/lib/librte_ethdev/rte_flow.h > index f3a8fb1..2a455b6 100644 > --- a/lib/librte_ethdev/rte_flow.h > +++ b/lib/librte_ethdev/rte_flow.h > @@ -1796,6 +1796,9 @@ struct rte_flow_action_rss { > uint32_t queue_num; /**< Number of entries in @p queue. */ > const uint8_t *key; /**< Hash key. */ > const uint16_t *queue; /**< Queue indices to use. */ > + struct rte_flow_item *inputset; /** Provide more specific inputset configuration. > + * ignore spec, only mask. > + */ > }; > > /** To make sure I understand, is this kind of a more flexible version of rte_flow_action_rss.types? For instance while specifying .types = ETH_RSS_IPV4 normally covers both source and destination addresses, does this approach enable users to perform RSS on source IP only? In which case, what value does the Toeplitz algorithm assume for the destination, 0x0? (note: must be documented) My opinion is that, unless you know of a hardware which can perform RSS on random bytes of a packet, this approach is a bit overkill at this point. How about simply adding the needed ETH_RSS_* definitions (e.g. ETH_RSS_IPV4_(SRC|DST))? How many are needed? There are currently 20 used bits and struct rte_flow_action_rss.types is 64-bit wide. I'm sure we can manage something without harming the ABI. Even better, you wouldn't need a deprecation notice. If you use the suggested approach, please update testpmd and its documentation as part of the same patch, thanks. -- Adrien Mazarguil 6WIND