Re: [Intel-wired-lan] [PATCH iwl-next v4 0/5] iavf: Add devlink and devlink rate support'

Zhang, Xuejun
2023-11-28T00:15:56Z

On 11/22/2023 7:22 PM, Jakub Kicinski wrote:
> On Wed, 22 Nov 2023 14:19:14 -0800 Zhang, Xuejun wrote:
>> The proposed API would incur net/core and driver changes as follows
>> a) existing drivers with ndo_set_tx_maxrate support upgraded to use new
>> ndo_set_tx_rate
>> b) net sysfs (replacing ndo_set_maxrate with ndo_set_tx_rate with
>> minrate and burst set to 0, -1 means ignore)
>> c) Keep the existing /sys/class/net/ethx/queues/tx_nn/tx_maxrate as it
>> is currently
>> d) Add sysfs entry as /sys/class/net/ethx/queues/tx_nn/tx_minrate &
>> /sys/class/net/ethx/queues/tx_nn/burst
> You described extending the sysfs API (which the ndo you mention
> is for) and nothing about converging the other existing APIs.
This is extension of ndo_set_tx_maxrate to include per queue parameters
of tx_minrate and burst.

devlink rate api includes tx_maxrate and tx_minrate, it is intended for
port rate configurations.

With regarding to tc mqprio, it is being used to configure queue group
per tc.

For sriov ndo ndo_set_vf_rate, that has been used for overall VF rate
configuration, not for queue based rate configuration.

It seems there are differences on intent of the aforementioned APIs.

Our use case here is to allow user (i.e @ uAPI) to configure tx rates of
max rate & min rate per VF queue.Hence we are inclined to
ndo_set_tx_maxrate extension.