[v1,1/3] bbdev: new queue stat for available enqueue depth

Message ID 20240404210447.1915517-2-nicolas.chautru@intel.com (mailing list archive)
State Changes Requested
Delegated to: Maxime Coquelin
Headers
Series Additional queue stats |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Chautru, Nicolas April 4, 2024, 9:04 p.m. UTC
Capturing additional queue stats counter for the
depth of enqueue batch still available on the given
queue. This can help application to monitor that depth
at run time.

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
 lib/bbdev/rte_bbdev.h | 2 ++
 1 file changed, 2 insertions(+)
  

Comments

Stephen Hemminger April 5, 2024, 12:46 a.m. UTC | #1
On Thu,  4 Apr 2024 14:04:45 -0700
Nicolas Chautru <nicolas.chautru@intel.com> wrote:

> Capturing additional queue stats counter for the
> depth of enqueue batch still available on the given
> queue. This can help application to monitor that depth
> at run time.
> 
> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>

Adding field is an ABI change and will have to wait until 24.11 release
  
Stephen Hemminger April 5, 2024, 3:15 p.m. UTC | #2
On Thu,  4 Apr 2024 14:04:45 -0700
Nicolas Chautru <nicolas.chautru@intel.com> wrote:

> Capturing additional queue stats counter for the
> depth of enqueue batch still available on the given
> queue. This can help application to monitor that depth
> at run time.
> 
> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
> ---
>  lib/bbdev/rte_bbdev.h | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h
> index 0cbfdd1c95..25514c58ac 100644
> --- a/lib/bbdev/rte_bbdev.h
> +++ b/lib/bbdev/rte_bbdev.h
> @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
>  	 *     bbdev operation
>  	 */
>  	uint64_t acc_offload_cycles;
> +	/** Available number of enqueue batch on that queue. */
> +	uint16_t enqueue_depth_avail;
>  };
>  
>  /**

Doesn't this break the ABI?
  
Chautru, Nicolas April 5, 2024, 6:17 p.m. UTC | #3
Hi Stephen, 

It is not strictly ABI compatible since the size of the structure increases, hence only updating for 24.11. 


> -----Original Message-----
> From: Stephen Hemminger <stephen@networkplumber.org>
> Sent: Friday, April 5, 2024 8:15 AM
> To: Chautru, Nicolas <nicolas.chautru@intel.com>
> Cc: dev@dpdk.org; maxime.coquelin@redhat.com; hemant.agrawal@nxp.com;
> Marchand, David <david.marchand@redhat.com>; Vargas, Hernan
> <hernan.vargas@intel.com>
> Subject: Re: [PATCH v1 1/3] bbdev: new queue stat for available enqueue depth
> 
> On Thu,  4 Apr 2024 14:04:45 -0700
> Nicolas Chautru <nicolas.chautru@intel.com> wrote:
> 
> > Capturing additional queue stats counter for the depth of enqueue
> > batch still available on the given queue. This can help application to
> > monitor that depth at run time.
> >
> > Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
> > ---
> >  lib/bbdev/rte_bbdev.h | 2 ++
> >  1 file changed, 2 insertions(+)
> >
> > diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h index
> > 0cbfdd1c95..25514c58ac 100644
> > --- a/lib/bbdev/rte_bbdev.h
> > +++ b/lib/bbdev/rte_bbdev.h
> > @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
> >  	 *     bbdev operation
> >  	 */
> >  	uint64_t acc_offload_cycles;
> > +	/** Available number of enqueue batch on that queue. */
> > +	uint16_t enqueue_depth_avail;
> >  };
> >
> >  /**
> 
> Doesn't this break the ABI?
  
Maxime Coquelin Aug. 12, 2024, 9:28 a.m. UTC | #4
Hi Nicolas,

On 4/4/24 23:04, Nicolas Chautru wrote:
> Capturing additional queue stats counter for the
> depth of enqueue batch still available on the given
> queue. This can help application to monitor that depth
> at run time.
> 
> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
> ---
>   lib/bbdev/rte_bbdev.h | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h
> index 0cbfdd1c95..25514c58ac 100644
> --- a/lib/bbdev/rte_bbdev.h
> +++ b/lib/bbdev/rte_bbdev.h
> @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
>   	 *     bbdev operation
>   	 */
>   	uint64_t acc_offload_cycles;
> +	/** Available number of enqueue batch on that queue. */
> +	uint16_t enqueue_depth_avail;
>   };
>   
>   /**

I think it needs to be documented in the ABI change section.

With that done, feel free to add:

Maxime Coquelin <maxime.coquelin@redhat.com>

Thanks,
Maxime
  
Maxime Coquelin Aug. 12, 2024, 9:56 a.m. UTC | #5
On 8/12/24 11:28, Maxime Coquelin wrote:
> Hi Nicolas,
> 
> On 4/4/24 23:04, Nicolas Chautru wrote:
>> Capturing additional queue stats counter for the
>> depth of enqueue batch still available on the given
>> queue. This can help application to monitor that depth
>> at run time.
>>
>> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
>> ---
>>   lib/bbdev/rte_bbdev.h | 2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h
>> index 0cbfdd1c95..25514c58ac 100644
>> --- a/lib/bbdev/rte_bbdev.h
>> +++ b/lib/bbdev/rte_bbdev.h
>> @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
>>        *     bbdev operation
>>        */
>>       uint64_t acc_offload_cycles;
>> +    /** Available number of enqueue batch on that queue. */
>> +    uint16_t enqueue_depth_avail;
>>   };
>>   /**
> 
> I think it needs to be documented in the ABI change section.
> 
> With that done, feel free to add:
> 
> Maxime Coquelin <maxime.coquelin@redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
> 
> Thanks,
> Maxime
  
Chautru, Nicolas Aug. 12, 2024, 5:27 p.m. UTC | #6
Hi Maxime, 

The branch origin/next-baseband-for-main doesn’t have yet the updates from main, such as the ./doc/rel_notes for 24.11. 
Can you refresh this? Or let me know how best to proceed.
Thanks, 
Nic

> -----Original Message-----
> From: Maxime Coquelin <maxime.coquelin@redhat.com>
> Sent: Monday, August 12, 2024 2:29 AM
> To: Chautru, Nicolas <nicolas.chautru@intel.com>; dev@dpdk.org
> Cc: hemant.agrawal@nxp.com; Marchand, David
> <david.marchand@redhat.com>; Vargas, Hernan
> <hernan.vargas@intel.com>
> Subject: Re: [PATCH v1 1/3] bbdev: new queue stat for available enqueue
> depth
> 
> Hi Nicolas,
> 
> On 4/4/24 23:04, Nicolas Chautru wrote:
> > Capturing additional queue stats counter for the depth of enqueue
> > batch still available on the given queue. This can help application to
> > monitor that depth at run time.
> >
> > Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
> > ---
> >   lib/bbdev/rte_bbdev.h | 2 ++
> >   1 file changed, 2 insertions(+)
> >
> > diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h index
> > 0cbfdd1c95..25514c58ac 100644
> > --- a/lib/bbdev/rte_bbdev.h
> > +++ b/lib/bbdev/rte_bbdev.h
> > @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
> >   	 *     bbdev operation
> >   	 */
> >   	uint64_t acc_offload_cycles;
> > +	/** Available number of enqueue batch on that queue. */
> > +	uint16_t enqueue_depth_avail;
> >   };
> >
> >   /**
> 
> I think it needs to be documented in the ABI change section.
> 
> With that done, feel free to add:
> 
> Maxime Coquelin <maxime.coquelin@redhat.com>
> 
> Thanks,
> Maxime
  
Maxime Coquelin Aug. 12, 2024, 7:44 p.m. UTC | #7
Hi Nicolas,

On 8/12/24 19:27, Chautru, Nicolas wrote:
> Hi Maxime,
> 
> The branch origin/next-baseband-for-main doesn’t have yet the updates from main, such as the ./doc/rel_notes for 24.11.
> Can you refresh this? Or let me know how best to proceed.

I rebased the branches to latest main, you can proceed.

Thanks,
Maxime

> Thanks,
> Nic
> 
>> -----Original Message-----
>> From: Maxime Coquelin <maxime.coquelin@redhat.com>
>> Sent: Monday, August 12, 2024 2:29 AM
>> To: Chautru, Nicolas <nicolas.chautru@intel.com>; dev@dpdk.org
>> Cc: hemant.agrawal@nxp.com; Marchand, David
>> <david.marchand@redhat.com>; Vargas, Hernan
>> <hernan.vargas@intel.com>
>> Subject: Re: [PATCH v1 1/3] bbdev: new queue stat for available enqueue
>> depth
>>
>> Hi Nicolas,
>>
>> On 4/4/24 23:04, Nicolas Chautru wrote:
>>> Capturing additional queue stats counter for the depth of enqueue
>>> batch still available on the given queue. This can help application to
>>> monitor that depth at run time.
>>>
>>> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
>>> ---
>>>    lib/bbdev/rte_bbdev.h | 2 ++
>>>    1 file changed, 2 insertions(+)
>>>
>>> diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h index
>>> 0cbfdd1c95..25514c58ac 100644
>>> --- a/lib/bbdev/rte_bbdev.h
>>> +++ b/lib/bbdev/rte_bbdev.h
>>> @@ -283,6 +283,8 @@ struct rte_bbdev_stats {
>>>    	 *     bbdev operation
>>>    	 */
>>>    	uint64_t acc_offload_cycles;
>>> +	/** Available number of enqueue batch on that queue. */
>>> +	uint16_t enqueue_depth_avail;
>>>    };
>>>
>>>    /**
>>
>> I think it needs to be documented in the ABI change section.
>>
>> With that done, feel free to add:
>>
>> Maxime Coquelin <maxime.coquelin@redhat.com>
>>
>> Thanks,
>> Maxime
>
  

Patch

diff --git a/lib/bbdev/rte_bbdev.h b/lib/bbdev/rte_bbdev.h
index 0cbfdd1c95..25514c58ac 100644
--- a/lib/bbdev/rte_bbdev.h
+++ b/lib/bbdev/rte_bbdev.h
@@ -283,6 +283,8 @@  struct rte_bbdev_stats {
 	 *     bbdev operation
 	 */
 	uint64_t acc_offload_cycles;
+	/** Available number of enqueue batch on that queue. */
+	uint16_t enqueue_depth_avail;
 };
 
 /**