netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* net_sched: gred: red_calc_qavg() called with current qavg for backlog?
@ 2012-04-21 18:46 Ward, David - 0663 - MITLL
  2012-04-21 20:10 ` David Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Ward, David - 0663 - MITLL @ 2012-04-21 18:46 UTC (permalink / raw)
  To: Thomas Graf, Eric Dumazet; +Cc: netdev@vger.kernel.org

In net/sched/sch_gred.c:

static int gred_dump(struct Qdisc *sch, struct sk_buff *skb)
{
     struct gred_sched *table = qdisc_priv(sch);
...
     for (i = 0; i < MAX_DPs; i++) {
         struct gred_sched_data *q = table->tab[i];
         struct tc_gred_qopt opt;
...
         opt.qave = red_calc_qavg(&q->parms, &q->vars, q->vars.qavg);


I can't tell if red_calc_qavg is intentionally being passed the current 
qavg as the backlog (which effectively causes qavg to only be 
re-calculated if we are idling)?  Or should this be:

         opt.qave = red_calc_qavg(&q->parms,
                                  &q->vars,
                                  gred_backlog(table, q, sch));

Thanks,

David

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-04-24 12:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-21 18:46 net_sched: gred: red_calc_qavg() called with current qavg for backlog? Ward, David - 0663 - MITLL
2012-04-21 20:10 ` David Miller
2012-04-24 12:37   ` Thomas Graf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).