This is basic Deficit Round Robin (DRR) algorithm, you cant just set
things arbitrarily, i am afraid ;->
Search for George Varghese's paper if you want to know more.
cheers,
jamal
On Fri, 8 Nov 2002, Ben Greear wrote:
> ### How can quota ever get negative? In other words, why not just
> set it to dev->weight always? Or, if the dev didn't use up all it's
> quota from the last round, why not
> ### increase it up to a max of 2 x weight or something like that?
>
> if (dev->quota < 0)
> dev->quota += dev->weight;
> else
> dev->quota = dev->weight;
> } else {
> dev_put(dev);
> local_irq_disable();
> }
> }
>
>
> --
> Ben Greear <greearb@xxxxxxxxxxxxxxx> <Ben_Greear AT excite.com>
> President of Candela Technologies Inc http://www.candelatech.com
> ScryMUD: http://scry.wanfear.com http://scry.wanfear.com/~greear
>
>
>
|