> -----Original Message----- > From: netdev-owner@xxxxxxxxxxxxxxx [mailto:netdev- > owner@xxxxxxxxxxxxxxx] On Behalf Of Ben Hutchings > Sent: Sunday, March 09, 2014 10:53 PM > To: Sucheta Chakraborty > Cc: David Miller; netdev; Dept-HSG Linux NIC Dev > Subject: Re: [RFC 1/2] net: Add support to configure SR-IOV VF minimum > and maximum Tx rate through ip tool. > > On Wed, 2014-03-05 at 02:33 -0500, Sucheta Chakraborty wrote: > > o A new handler set_vf_rate for attr IFLA_VF_RATE has been introduced > > which takes 4 arguments: > > netdev, VF number, min_tx_rate, max_tx_rate > > > > o min_tx_rate puts lower limit on the VF bandwidth. VF is guaranteed > > to have a bandwidth of at least this value. > > max_tx_rate puts cap on the VF bandwidth. VF can have a bandwidth > > of up to this value. > > Supposing I only want to set a minimum, how would I specify that there > is no maximum? > Sucheta> The current implementation allows user to send only min_tx_rate as well. In that case, max_tx_rate is read back from driver and passed as it is. If user has not done any setting with respect to max_tx_rate till now, the default max returned by driver will be used. > > o Idea is to deprecate IFLA_VF_TX_RATE and ndo_set_vf_tx_rate in > future. > > And to have consistent display of rate values to user. > [...] > > You can't deprecate the userland interface, but the driver operation > should be replaced at the same time. > > - The rtnetlink core should combine userland settings from > IFLA_VF_TX_RATE and IFLA_VF_RATE. If both are specified, I think > IFLA_VF_RATE should override. > - If only IFLA_VF_TX_RATE is specified, the core should get the current > minimum before calling ndo_set_vf_rate. > - Drivers that currently implement ndo_set_vf_tx_rate should be > converted to implement ndo_set_vf_rate and reject attempts to set a > minimum bandwidth greater than 0. > Sucheta> Ok. By minimum bandwidth 0, did you mean driver specified default for minimum BW? So, drivers that currently implement ndo_set_vf_tx_rate should call ndo_set_vf_rate instead, with default minimum BW set for the driver. > Ben. > > -- > Ben Hutchings > I say we take off; nuke the site from orbit. It's the only way to be > sure. Thanks for your comments. Regards, Sucheta. ��.n��������+%������w��{.n����z����ܨ}���Ơz�j:+v�����w����ޙ��&�)ߡ�a����z�ޗ���ݢj��w�f