DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ferruh Yigit <ferruh.yigit@intel.com>
To: Slava Ovsiienko <viacheslavo@nvidia.com>,
	Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>,
	Ajit Khaparde <ajit.khaparde@broadcom.com>,
	Somnath Kotur <somnath.kotur@broadcom.com>,
	Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Cc: "NBU-Contact-Thomas Monjalon (EXTERNAL)" <thomas@monjalon.net>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: Re: [PATCH v3] ethdev: deprecate header fields and metadata flow actions
Date: Thu, 25 Nov 2021 15:14:07 +0000	[thread overview]
Message-ID: <bd58e066-3d9a-7414-e6d6-78f307d5a119@intel.com> (raw)
In-Reply-To: <DM6PR12MB3753657A05F909DA6614693CDF629@DM6PR12MB3753.namprd12.prod.outlook.com>

On 11/25/2021 1:56 PM, Slava Ovsiienko wrote:
>> -----Original Message-----
>> From: Ferruh Yigit <ferruh.yigit@intel.com>
>> Sent: Thursday, November 25, 2021 13:54
>> To: Andrew Rybchenko <andrew.rybchenko@oktetlabs.ru>; Ajit Khaparde
>> <ajit.khaparde@broadcom.com>; Somnath Kotur
>> <somnath.kotur@broadcom.com>; Rahul Lakkireddy
>> <rahul.lakkireddy@chelsio.com>; Slava Ovsiienko <viacheslavo@nvidia.com>
>> Cc: NBU-Contact-Thomas Monjalon (EXTERNAL) <thomas@monjalon.net>;
>> dev@dpdk.org
>> Subject: Re: [PATCH v3] ethdev: deprecate header fields and metadata flow
>> actions
>>
>> On 11/24/2021 3:37 PM, Viacheslav Ovsiienko wrote:
>>> The generic RTE_FLOW_ACTION_TYPE_MODIFY_FIELD action was
>> introduced by
>>> [1]. This action provides an unified way to perform various arithmetic
>>> and transfer operations over packet network header fields and packet
>>> metadata.
>>>
>>> [1] commit 641dbe4fb053 ("net/mlx5: support modify field flow action")
>>>
>>> On other side there are a bunch of multiple legacy actions, that can
>>> be superseded by the generic modify field action:
> [.. snip ..]
>>>
>>> The VLAN set actions are interrelated to VLAN header insertion/removal
>>> and supported by multiple PMDs and supposed to be just deprecated but
>>> not be removed in 22.11.
>>>
>>
>> Why not remove them for v22.11? Do you think PMDs can't change the
>> existing implementation until 22.11?
> 
> Yes,  this is a main concern - these actions are supported by multiple PMDs,
> and its handling might be a little bit complicated. For example, in mlx5
> SET_VLAN_ID can be translated into different HW/FW primitives
> depending on presence of PUSH_VLAN action. I think any PMD should do
> the check of VLAN actions order for the case of PUSH, replacing with
> MODIFY_FIELD would sophisticate the check
> 
> In mlx5 we are going to support MODIFY_FIELD and kept SET_VLAN_XX
> in any combinations, but, actually, there is no objection about dropping
> SET_VLAN_XXX  regarding mlx5. I just would not like to force
> the commitments for that from other PMDs.
> 
>>> Signed-off-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>
>>>
>>> --
>>> v2  - deprecation.rst is updated
>>> v3  - doc comments addressed
>>>       - commit message comments addressed
>>>       - SET_VLAN_VID and SET_VLAN_PCP actions deprecated, but will not
>>>         be removed in 22.11
>>
>> Deprecated symbols are to prevent new code using them, but for this case
>> there is no alternative, since PMDs still don't support
>> 'RTE_FLOW_ACTION_TYPE_MODIFY_FIELD' yet.
>> This patch is forcing users to use deprecated actions (except from mlx).
>>
>> What about a slight change:
>> 1- In this release, update header/document as
>> 'RTE_FLOW_ACTION_TYPE_MODIFY_FIELD'
>>      is preferred way if supported. Instead of deprecating old ones.
>>
>> 2- Have an agreement with PMD maintainers to switch to new action before
>> v22.11,
>>      and don't accept old action implementation in PMDs anymore.
>>      Based on agreement update 'deprecation.rst' in this release to note that
>>      old actions will be removed on v22.11.
>>      (It would be good to have a check to prevent old actions merged during that
>> time.)
>>
>> 3- In v22.11, remove old actions, the PMDs that don't support MODIFY_FIELD
>>      action will lose the feature.
>>
>> What do you think?
> 
> In my opinion, deprecation warns about coming changes - entity is going to be
> removed or changed. It does not force to take some immediate action now,
> just to be aware about.
> 
> There are two questions:
> - do we want to replace a bunch of legacy actions with new one? I suppose - yes, there
>    is a lot of advantages
> - are we going to do this with MODIFY_FIELD? Yes, this is an intention.
> 
> So, we have answers for these questions now, and should handle legacy actions accordingly -
> mark as deprecated and provide the clue about MODIFY_FIELD.
> 
> The question remaining - how we are going to proceed. Actions can't be removed till
> alternative is provided. So, in my understanding the process should be:
> 
> A. mark actions as deprecated, to advertise an intention
> B. implement MODIFY_FIELD support (maintainers agreement/commitment), assign the due date for this
> C. advertise the date of legacy actions removal (if it was not claimed in B)
> D. remove legacy actions entirely
> 
> We are doing step A now.
> Also step B is imposed by advertising the removal date. It is ultimate approach, and is not exactly what we need.
> Do we have alternative softened way to encourage PMDs to be updated? No objections to follow 😊.
> 

We are aligned on the intention.

For (A), those symbols interface with both drivers and applications,
for drivers no concern on deprecating the symbols but I think it is wrong
to deprecate from applications perspective.

Slightly updated version:
A. document legacy actions as not preferred way, but applications still can use them,
    and no change is required by applications (unless they prefer to use new action).
    For PMDs we don't allow any more implementation of these actions.
B. PMDs implement 'MODIFY_FIELD', have a deadline for it (same with your B.)
    Assuming deadline is v22.11, announce that old actions will be deprecated
    on v22.11 in this release.
C. on v22.11 deprecate old actions, exiting applications still can use them
    but new code should use 'MODIFY_FIELD' action.
    Announce removal date for the legacy actions
D. Remove legacy actions entirely

Down side is, from this release to until legacy actions are removed, PMD
needs to maintain both legacy and 'MODIFY_FIELD' actions.
But hopefully can provide smooth transitions for the applications.

What do you think?

btw, this for the legacy actions that is implemented at least by one PMD,
we can remove the ones that are not implemented.

> Summary:
> - If we are OK about intention - step A should be taken, we should emit deprecation
> - we need to gain "B". Now it is proposed to do with advertising the removal date. Alternatives?
> 
> With best regards,
> Slava
> 


  reply	other threads:[~2021-11-25 15:14 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-23  7:59 [PATCH] " Viacheslav Ovsiienko
2021-11-24  8:06 ` [PATCH v2] " Viacheslav Ovsiienko
2021-11-24 14:56   ` Thomas Monjalon
2021-11-24 15:37 ` [PATCH v3] " Viacheslav Ovsiienko
2021-11-24 15:59   ` Thomas Monjalon
2021-11-24 16:21   ` Ori Kam
2021-11-24 16:37     ` Slava Ovsiienko
2021-11-24 17:32       ` Thomas Monjalon
2021-11-24 18:09         ` Ori Kam
2021-11-25 11:53   ` Ferruh Yigit
2021-11-25 12:03     ` Somnath Kotur
2021-11-25 13:06     ` Thomas Monjalon
2021-11-25 14:13       ` Slava Ovsiienko
2021-11-25 14:40         ` Ferruh Yigit
2021-11-25 14:52           ` Slava Ovsiienko
2021-11-25 14:15       ` Ferruh Yigit
2021-11-25 13:56     ` Slava Ovsiienko
2021-11-25 15:14       ` Ferruh Yigit [this message]
2021-11-25 15:53         ` Thomas Monjalon
2021-11-25 12:18   ` Ferruh Yigit
2021-11-25 12:29     ` Ori Kam
2021-11-25 12:46       ` Ferruh Yigit
2021-11-25 13:56         ` Ori Kam
2021-11-25 14:28           ` Ferruh Yigit
2021-11-25 12:31   ` Ferruh Yigit
2021-11-25 12:50     ` Thomas Monjalon
2021-11-26  9:51 ` [PATCH v4] " Viacheslav Ovsiienko
2021-11-26 12:53   ` Ferruh Yigit
2021-11-26 13:06     ` Thomas Monjalon
2021-11-26 14:52       ` Olivier Matz
2021-11-26 17:07         ` Thomas Monjalon

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=bd58e066-3d9a-7414-e6d6-78f307d5a119@intel.com \
    --to=ferruh.yigit@intel.com \
    --cc=ajit.khaparde@broadcom.com \
    --cc=andrew.rybchenko@oktetlabs.ru \
    --cc=dev@dpdk.org \
    --cc=rahul.lakkireddy@chelsio.com \
    --cc=somnath.kotur@broadcom.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).