ethdev: rename tunnel offload callbacks

Message ID 20201018121523.4408-1-getelson@nvidia.com (mailing list archive)
State Accepted, archived
Delegated to: Ferruh Yigit
Headers
Series ethdev: rename tunnel offload callbacks |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-testing success Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/Intel-compilation success Compilation OK
ci/iol-mellanox-Performance success Performance Testing PASS

Commit Message

Etelson, Gregory Oct. 18, 2020, 12:15 p.m. UTC
rename new rte_flow ops callbacks to emphasize relation to tunnel
offload API.

Signed-off-by: Gregory Etelson <getelson@nvidia.com>
Acked-by: Ori Kam <orika@nvidia.com>
---
 lib/librte_ethdev/rte_flow.c        | 13 +++++++------
 lib/librte_ethdev/rte_flow_driver.h |  4 ++--
 2 files changed, 9 insertions(+), 8 deletions(-)
  

Comments

Ferruh Yigit Oct. 19, 2020, 8:31 a.m. UTC | #1
On 10/18/2020 1:15 PM, Gregory Etelson wrote:
> rename new rte_flow ops callbacks to emphasize relation to tunnel
> offload API.
> 
> Signed-off-by: Gregory Etelson <getelson@nvidia.com>
> Acked-by: Ori Kam <orika@nvidia.com>
> ---
>   lib/librte_ethdev/rte_flow.c        | 13 +++++++------
>   lib/librte_ethdev/rte_flow_driver.h |  4 ++--
>   2 files changed, 9 insertions(+), 8 deletions(-)
> 
> diff --git a/lib/librte_ethdev/rte_flow.c b/lib/librte_ethdev/rte_flow.c
> index 380c5cae2c..d3e5cbc194 100644
> --- a/lib/librte_ethdev/rte_flow.c
> +++ b/lib/librte_ethdev/rte_flow.c
> @@ -1223,10 +1223,11 @@ rte_flow_tunnel_action_decap_release(uint16_t port_id,
>   
>   	if (unlikely(!ops))
>   		return -rte_errno;
> -	if (likely(!!ops->action_release)) {
> +	if (likely(!!ops->tunnel_action_decap_release)) {

+1 to rename.

Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
  
Ray Kinsella Oct. 19, 2020, 9:56 a.m. UTC | #2
On 19/10/2020 09:31, Ferruh Yigit wrote:
> On 10/18/2020 1:15 PM, Gregory Etelson wrote:
>> rename new rte_flow ops callbacks to emphasize relation to tunnel
>> offload API.
>>
>> Signed-off-by: Gregory Etelson <getelson@nvidia.com>
>> Acked-by: Ori Kam <orika@nvidia.com>
>> ---
>>   lib/librte_ethdev/rte_flow.c        | 13 +++++++------
>>   lib/librte_ethdev/rte_flow_driver.h |  4 ++--
>>   2 files changed, 9 insertions(+), 8 deletions(-)
>>
>> diff --git a/lib/librte_ethdev/rte_flow.c b/lib/librte_ethdev/rte_flow.c
>> index 380c5cae2c..d3e5cbc194 100644
>> --- a/lib/librte_ethdev/rte_flow.c
>> +++ b/lib/librte_ethdev/rte_flow.c
>> @@ -1223,10 +1223,11 @@ rte_flow_tunnel_action_decap_release(uint16_t port_id,
>>         if (unlikely(!ops))
>>           return -rte_errno;
>> -    if (likely(!!ops->action_release)) {
>> +    if (likely(!!ops->tunnel_action_decap_release)) {
> 
> +1 to rename.
> 
> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>

Acked-by: Ray Kinsella <mdr@ashroe.eu>
  
Thomas Monjalon Oct. 19, 2020, 9:29 p.m. UTC | #3
19/10/2020 11:56, Kinsella, Ray:
> On 19/10/2020 09:31, Ferruh Yigit wrote:
> > On 10/18/2020 1:15 PM, Gregory Etelson wrote:
> >> rename new rte_flow ops callbacks to emphasize relation to tunnel
> >> offload API.
> >>
> >> Signed-off-by: Gregory Etelson <getelson@nvidia.com>
> >> Acked-by: Ori Kam <orika@nvidia.com>
> > 
> > +1 to rename.
> > 
> > Acked-by: Ferruh Yigit <ferruh.yigit@intel.com>
> 
> Acked-by: Ray Kinsella <mdr@ashroe.eu>

Applied, thanks
  

Patch

diff --git a/lib/librte_ethdev/rte_flow.c b/lib/librte_ethdev/rte_flow.c
index 380c5cae2c..d3e5cbc194 100644
--- a/lib/librte_ethdev/rte_flow.c
+++ b/lib/librte_ethdev/rte_flow.c
@@ -1223,10 +1223,11 @@  rte_flow_tunnel_action_decap_release(uint16_t port_id,
 
 	if (unlikely(!ops))
 		return -rte_errno;
-	if (likely(!!ops->action_release)) {
+	if (likely(!!ops->tunnel_action_decap_release)) {
 		return flow_err(port_id,
-				ops->action_release(dev, actions,
-						    num_of_actions, error),
+				ops->tunnel_action_decap_release(dev, actions,
+								 num_of_actions,
+								 error),
 				error);
 	}
 	return rte_flow_error_set(error, ENOTSUP,
@@ -1245,10 +1246,10 @@  rte_flow_tunnel_item_release(uint16_t port_id,
 
 	if (unlikely(!ops))
 		return -rte_errno;
-	if (likely(!!ops->item_release)) {
+	if (likely(!!ops->tunnel_item_release)) {
 		return flow_err(port_id,
-				ops->item_release(dev, items,
-						  num_of_items, error),
+				ops->tunnel_item_release(dev, items,
+							 num_of_items, error),
 				error);
 	}
 	return rte_flow_error_set(error, ENOTSUP,
diff --git a/lib/librte_ethdev/rte_flow_driver.h b/lib/librte_ethdev/rte_flow_driver.h
index bd5ffc0bb1..f3d72827cc 100644
--- a/lib/librte_ethdev/rte_flow_driver.h
+++ b/lib/librte_ethdev/rte_flow_driver.h
@@ -152,13 +152,13 @@  struct rte_flow_ops {
 		 struct rte_flow_restore_info *info,
 		 struct rte_flow_error *err);
 	/** See rte_flow_action_tunnel_decap_release() */
-	int (*action_release)
+	int (*tunnel_action_decap_release)
 		(struct rte_eth_dev *dev,
 		 struct rte_flow_action *pmd_actions,
 		 uint32_t num_of_actions,
 		 struct rte_flow_error *err);
 	/** See rte_flow_item_release() */
-	int (*item_release)
+	int (*tunnel_item_release)
 		(struct rte_eth_dev *dev,
 		 struct rte_flow_item *pmd_items,
 		 uint32_t num_of_items,