On 9/23/2019 9:12 AM, Tiwei Bie wrote:
> On Tue, Sep 17, 2019 at 05:09:47PM +0800, Andy Pei wrote:
>> vDPA's set_vring_state callback would need to know the virtqueues'
>> enable status to configure the hardware.
>>
>> Signed-off-by: Xiaolong Ye <xiaolong...@intel.com>
>> Signed-off-by: Andy Pei <andy....@intel.com>
>> ---
>> v2:
>>  add nr_active_vring as a parameter to ops function set_vring_state in
>>  case of callback in set_vring_state() and avoid exposing new API.
>>
>>  lib/librte_vhost/rte_vdpa.h   |  4 ++--
>>  lib/librte_vhost/vhost_user.c | 27 +++++++++++++++++++++++++--
>>  2 files changed, 27 insertions(+), 4 deletions(-)
>>
>> diff --git a/lib/librte_vhost/rte_vdpa.h b/lib/librte_vhost/rte_vdpa.h
>> index 9a3deb3..6e55d4d 100644
>> --- a/lib/librte_vhost/rte_vdpa.h
>> +++ b/lib/librte_vhost/rte_vdpa.h
>> @@ -54,8 +54,8 @@ struct rte_vdpa_dev_ops {
>>      int (*dev_conf)(int vid);
>>      int (*dev_close)(int vid);
>>  
>> -    /** Enable/disable this vring */
>> -    int (*set_vring_state)(int vid, int vring, int state);
>> +    /** Enable/disable vring queue pairs */
>> +    int (*set_vring_state)(int vid, int nr_active_vring);
> 
> We should avoid changing the API/ABI unless we have a very good
> justification.
> 
> With the existing API, it should be easy to get the number of
> active rings by maintaining a bitmap or something similar in
> ifc driver.
> 
> Besides, please keep other maintainers got from get-maintainer.sh
> in the Cc list as well.
> 

updating patchset [1] as "Change Requested" based on above comment.

[1]
https://patches.dpdk.org/user/todo/dpdk/?series=6424&delegate=319&state=*

Reply via email to