DPDK patches and discussions
 help / color / mirror / Atom feed
From: Bing Zhao <bingz@nvidia.com>
To: Ferruh Yigit <ferruh.yigit@intel.com>, Ori Kam <orika@nvidia.com>,
	NBU-Contact-Thomas Monjalon <thomas@monjalon.net>,
	"andrew.rybchenko@oktetlabs.ru" <andrew.rybchenko@oktetlabs.ru>,
	Matan Azrad <matan@nvidia.com>,
	Slava Ovsiienko <viacheslavo@nvidia.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	"ajit.khaparde@broadcom.com" <ajit.khaparde@broadcom.com>,
	Gregory Etelson <getelson@nvidia.com>,
	Andrey Vesnovaty <andreyv@nvidia.com>
Subject: Re: [dpdk-dev] [PATCH v2 1/4] ethdev: introduce indirect action APIs
Date: Tue, 13 Apr 2021 01:26:55 +0000	[thread overview]
Message-ID: <MN2PR12MB2909197B3C20EE16103AF647D04F9@MN2PR12MB2909.namprd12.prod.outlook.com> (raw)
In-Reply-To: <728b94bb-b5fa-37bd-ecc8-411fcac1465f@intel.com>

Hi Ferruh,

> -----Original Message-----
> From: Ferruh Yigit <ferruh.yigit@intel.com>
> Sent: Tuesday, April 13, 2021 3:42 AM
> To: Bing Zhao <bingz@nvidia.com>; Ori Kam <orika@nvidia.com>; NBU-
> Contact-Thomas Monjalon <thomas@monjalon.net>;
> andrew.rybchenko@oktetlabs.ru; Matan Azrad <matan@nvidia.com>; Slava
> Ovsiienko <viacheslavo@nvidia.com>
> Cc: dev@dpdk.org; ajit.khaparde@broadcom.com; Gregory Etelson
> <getelson@nvidia.com>; Andrey Vesnovaty <andreyv@nvidia.com>
> Subject: Re: [PATCH v2 1/4] ethdev: introduce indirect action APIs
> 
> External email: Use caution opening links or attachments
> 
> 
> On 4/10/2021 3:03 PM, Bing Zhao wrote:
> > Right now, rte_flow_shared_action_* APIs are used for some shared
> > actions, like RSS, count. The shared action should be created
> before
> > using it inside a flow. These shared actions sometimes are not
> really
> > shared but just some indirect actions decoupled from a flow.
> >
> > The new functions rte_flow_action_handle_* are added to replace
> the
> > current shared functions rte_flow_shared_action_*.
> >
> > There are two types of flow actions:
> > 1. the direct (normal) actions that could be created and stored
> >     within a flow rule. Such action is tied to its flow rule and
> >     cannot be reused.
> > 2. the indirect action, in the past, named shared_action. It is
> >     created from a direct actioni, like count or rss, and then
> used
> >     in the flow rules with an object handle. The PMD will take
> care
> >     of the retrieve from indirect action to the direct action
> >     when it is referenced.
> >
> > The indirect action is accessed (update / query) w/o any flow rule,
> > just via the action object handle. For example, when querying or
> > resetting a counter, it could be done out of any flow using this
> > counter, but only the handle of the counter action object is
> required.
> > The indirect action object could be shared by different flows or
> used
> > by a single flow, depending on the direct action type and the
> > real-life requirements.
> > The handle of an indirect action object is opaque and defined in
> each
> > driver and possibly different per direct action type.
> >
> > The old name "shared" is improper in a sense and should be
> replaced.
> >
> > All the command lines in testpmd application with "shared_action*"
> > are replaced with "indirect_action*".
> >
> > The parameter of "update" interface is also changed. A general
> pointer
> > will replace the rte_flow_action struct pointer due to the
> > facts:
> > 1. Some action may not support fields updating. In the example of
> a
> >     counter, the only "update" supported should be the reset. So
> >     passing a rte_flow_action struct pointer is meaningless and
> >     there is even no such corresponding action struct. What's more,
> >     if more than one operations should be supported, for some
> other
> >     action, such pointer parameter may not meet the need.
> > 2. Some action may need conditional or partial update, the current
> >     parameter will not provide the ability to indicate which
> part(s)
> >     to update.
> >     For different types of indirect action objects, the pointer
> could
> >     either be the same of rte_flow_action* struct - in order not
> to
> >     break the current driver implementation, or some wrapper
> >     structures with bits as masks to indicate which part to be
> >     updated, depending on real needs of the corresponding direct
> >     action. For different direct actions, the structures of
> indirect
> >     action objects updating will be different.
> >
> > All the underlayer PMD callbacks will be moved to these new APIs.
> >
> > The RTE_FLOW_ACTION_TYPE_SHARED is kept for now in order not to
> break
> > the ABI. All the implementations are changed by using
> > RTE_FLOW_ACTION_TYPE_INDIRECT.
> >
> > Signed-off-by: Bing Zhao <bingz@nvidia.com>
> > ---
> >   doc/guides/rel_notes/release_21_05.rst |   3 +
> >   lib/librte_ethdev/rte_flow.c           |  56 ++++++++--------
> >   lib/librte_ethdev/rte_flow.h           | 118
> +++++++++++++++++++--------------
> >   lib/librte_ethdev/rte_flow_driver.h    |  26 ++++----
> >   lib/librte_ethdev/version.map          |   8 +--
> 
> Isn't there any documentation to update with this change?

Do you mean the release note? I only updated the 20_01 release note part.

> 
> If the shared action API is not documented at all, can you please
> add documentation for the action handle API?

In the testpmd usage guide, I found some description and update it together with the testpmd update.
I will check if there is another place to update or add.

Thanks

BR. Bing

  reply	other threads:[~2021-04-13  1:26 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1615967952-228321-1-git-send-email-bingz@nvidia.com>
2021-03-17  8:28 ` [dpdk-dev] [RFC] ethdev: introduce action context APIs Thomas Monjalon
2021-03-17 16:10   ` Bing Zhao
2021-03-22 14:59     ` Andrew Rybchenko
2021-04-06  9:05       ` Bing Zhao
2021-03-22 14:54   ` Andrew Rybchenko
2021-04-06  9:07     ` Bing Zhao
2021-04-06  9:48       ` Thomas Monjalon
2021-04-06 11:02         ` Bing Zhao
2021-04-06 12:18           ` Thomas Monjalon
2021-04-07  3:16         ` Ajit Khaparde
2021-04-07  6:11           ` Bing Zhao
2021-04-08 14:46 ` [dpdk-dev] [RFC PATCH v2] ethdev: introduce indirect action APIs Bing Zhao
2021-04-09  3:54 ` [dpdk-dev] [PATCH] " Bing Zhao
2021-04-10 14:03   ` [dpdk-dev] [PATCH v2 0/4] Change shared action API to action handle API Bing Zhao
2021-04-10 14:03     ` [dpdk-dev] [PATCH v2 1/4] ethdev: introduce indirect action APIs Bing Zhao
2021-04-12 19:42       ` Ferruh Yigit
2021-04-13  1:26         ` Bing Zhao [this message]
2021-04-13 14:00           ` Ori Kam
2021-04-13 12:36       ` Andrey Vesnovaty
2021-04-15 13:55       ` Andrew Rybchenko
2021-04-15 14:10         ` Thomas Monjalon
2021-04-15 16:02           ` Andrew Rybchenko
2021-04-10 14:03     ` [dpdk-dev] [PATCH v2 2/4] app/test-pmd: change to indirect action command Bing Zhao
2021-04-10 14:03     ` [dpdk-dev] [PATCH v2 3/4] doc: update user guide for indirect action Bing Zhao
2021-04-10 14:03     ` [dpdk-dev] [PATCH v2 4/4] net/mlx5: adaption to indirect action API Bing Zhao
2021-04-12 19:40     ` [dpdk-dev] [PATCH v2 0/4] Change shared action API to action handle API Ferruh Yigit
2021-04-13  1:22       ` Bing Zhao
2021-04-13  7:23         ` Thomas Monjalon
2021-04-13  7:24           ` Bing Zhao
2021-04-15 15:51   ` [dpdk-dev] [PATCH v3 0/1] " Bing Zhao
2021-04-15 15:51     ` [dpdk-dev] [PATCH v3 1/1] ethdev: introduce indirect action APIs Bing Zhao
2021-04-15 15:56       ` Ori Kam
2021-04-15 17:59       ` Ajit Khaparde
2021-04-16  6:58         ` Bing Zhao
2021-04-16  7:03         ` Thomas Monjalon
2021-04-16 15:00           ` Ajit Khaparde
2021-04-16 17:33   ` [dpdk-dev] [PATCH v4 0/1] Change shared action API to action handle API Bing Zhao
2021-04-16 17:33     ` [dpdk-dev] [PATCH v4 1/1] ethdev: introduce indirect action APIs Bing Zhao
2021-04-19 12:26       ` Thomas Monjalon
2021-04-19 15:05         ` Bing Zhao
2021-04-19 14:28   ` [dpdk-dev] [PATCH v5] Change shared action API to action handle API Bing Zhao
2021-04-19 14:28     ` [dpdk-dev] [PATCH v5] ethdev: introduce indirect action APIs Bing Zhao
2021-04-19 14:38   ` [dpdk-dev] [PATCH v5 0/1] Change shared action API to action handle API Bing Zhao
2021-04-19 14:38     ` [dpdk-dev] [PATCH v5 1/1] ethdev: introduce indirect action APIs Bing Zhao
2021-04-19 14:50       ` Thomas Monjalon
2021-04-19 15:09         ` Ferruh Yigit

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=MN2PR12MB2909197B3C20EE16103AF647D04F9@MN2PR12MB2909.namprd12.prod.outlook.com \
    --to=bingz@nvidia.com \
    --cc=ajit.khaparde@broadcom.com \
    --cc=andrew.rybchenko@oktetlabs.ru \
    --cc=andreyv@nvidia.com \
    --cc=dev@dpdk.org \
    --cc=ferruh.yigit@intel.com \
    --cc=getelson@nvidia.com \
    --cc=matan@nvidia.com \
    --cc=orika@nvidia.com \
    --cc=thomas@monjalon.net \
    --cc=viacheslavo@nvidia.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).