From: Eric Dumazet <eric.dumazet@gmail.com>
To: Fabio Checconi <fchecconi@gmail.com>
Cc: Stephen Hemminger <shemminger@vyatta.com>,
David Miller <davem@davemloft.net>,
Luigi Rizzo <rizzo@iet.unipi.it>,
netdev@vger.kernel.org, Paolo Valente <paolo.valente@unimore.it>
Subject: Re: [PATCH] sched: QFQ - quick fair queue scheduler (v2)
Date: Thu, 03 Mar 2011 09:27:48 +0100 [thread overview]
Message-ID: <1299140868.2456.35.camel@edumazet-laptop> (raw)
In-Reply-To: <20110303081940.GA29685@gandalf.sssup.it>
Le jeudi 03 mars 2011 à 09:19 +0100, Fabio Checconi a écrit :
> Hi,
>
> > From: Eric Dumazet <eric.dumazet@gmail.com>
> > Date: Wed, Mar 02, 2011 06:31:27PM +0100
> >
> > Le mercredi 02 mars 2011 à 17:18 +0100, Eric Dumazet a écrit :
> > > Le mercredi 02 mars 2011 à 08:11 -0800, Stephen Hemminger a écrit :
> > >
> > > > I put the iproute2 code into the repository in the experimental branch.
> > > >
> > >
> > > Thanks
> > >
> > > It seems as soon as packets are dropped, qdisc is frozen (no more
> > > packets dequeued)
>
> I've been able to reproduce this problem using netem, and it seems to
> be due to this check:
>
> > + /* If the new skb is not the head of queue, then done here. */
> > + if (skb != qdisc_peek_head(cl->qdisc))
> > + return err;
>
> changing it to:
>
> if (cl->qdisc->q.qlen != 1)
> return err;
>
> seems to make things work. I think this is because qdisc_peek_head()
> looks at the wrong list, as the skb is not queued directly in q, but
> ends up in the child qdisc attached to cl->qdisc.
>
Strange, I used the default qdisc (pfifo) created in qfq classes
>
> > >
> > > Hmm...
> > >
> >
> > It seems class deletes are buggy.
> >
> > After one "tc class del dev $ETH classid 11:1 ..."
> >
> > a "tc -s -d qdisc show dev $ETH" triggers an Oops
> >
>
> This seems to be due to:
>
> > +static void qfq_destroy_class(struct Qdisc *sch, struct qfq_class *cl)
> > +{
> > + struct qfq_sched *q = (struct qfq_sched *)sch;
>
> it should be:
>
> struct qfq_sched *q = sched_priv(sch);
>
> The same bug you identified in qfq_reset_qdisc() is present also in
> qfq_drop(), both loops need to be corrected...
>
> It should also be noted that this scheduler (like HFSC, IIRC) depends
> on the child qdisc not to reorder packets for the guarantees to be met,
> as the timestamps need to be in sync with the length of the packet at the
> head of the queue. If this can't be guaranteed, to preserve the formal
> correctness it should be changed to always use the maximum packet size
> to calculate the timestamps.
>
> @Stephen: not that I'm proud of that, but all the bugs found so far are mine...
I am going to test an updated version, thanks for all these hints !
next prev parent reply other threads:[~2011-03-03 8:37 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-01 1:17 [PATCH] sched: QFQ - quick fair queue scheduler (v2) Stephen Hemminger
2011-03-01 5:28 ` Eric Dumazet
2011-03-02 2:06 ` Fabio Checconi
2011-03-02 11:17 ` Eric Dumazet
2011-03-02 16:11 ` Stephen Hemminger
2011-03-02 16:18 ` Eric Dumazet
2011-03-02 17:31 ` Eric Dumazet
2011-03-02 18:16 ` Patrick McHardy
2011-03-03 9:35 ` Eric Dumazet
2011-03-02 23:55 ` Stephen Hemminger
2011-03-03 8:19 ` Fabio Checconi
2011-03-03 8:27 ` Eric Dumazet [this message]
2011-03-03 10:40 ` Eric Dumazet
2011-03-03 15:07 ` Fabio Checconi
2011-03-03 15:25 ` Eric Dumazet
2011-03-03 15:31 ` Eric Dumazet
2011-03-03 15:39 ` Eric Dumazet
2011-03-03 15:18 ` Eric Dumazet
[not found] ` <20110303161912.GC29685@gandalf.sssup.it>
[not found] ` <1299170053.2983.134.camel@edumazet-laptop>
[not found] ` <20110303181339.GD29685@gandalf.sssup.it>
[not found] ` <1299180567.2547.4.camel@edumazet-laptop>
[not found] ` <1299192974.2547.13.camel@edumazet-laptop>
[not found] ` <20110304064302.GE29685@gandalf.sssup.it>
[not found] ` <1299222074.2547.50.camel@edumazet-laptop>
[not found] ` <AANLkTinAGjZ5SAOA1iUAFu5rtYydeb6Soy_Xg5kMvn-z@mail.gmail.com>
[not found] ` <1299274468.2758.4.camel@edumazet-laptop>
[not found] ` <AANLkTikeQCfShKfZWq2Y7V_MA4iRjQvWWtkC68rK9nUm@mail.gmail.com>
[not found] ` <1299277003.2758.52.camel@edumazet-laptop>
[not found] ` <AANLkTinR7QDC2uGjQurJQ1JfBA7q1pxyewePggh87z8E@mail.gmail.com>
[not found] ` <1299278778.2758.53.camel@edumazet-laptop>
[not found] ` <AANLkTikBoQd+ZA1kY0F0MvUsJ8Y=9KwGkfmZNdi4hLXz@mail.gmail.com>
[not found] ` <20110304150741.5d4aa354@nehalam>
[not found] ` <AANLkTi=HBDayfd0bEA+AQqzjTKMajghet=UJAw9vL56A@mail.gmail.com>
[not found] ` <20110309110242.3307ca69@nehalam>
[not found] ` <1300016057.2761.16.camel@edumazet-laptop>
[not found] ` <1300034690.2761.29.camel@edumazet-laptop>
2011-03-23 6:45 ` [BUG] net_sched: failed bisection Eric Dumazet
2011-03-24 6:53 ` [PATCH] net_sched: fix THROTTLED/RUNNING race Eric Dumazet
2011-03-24 7:13 ` David Miller
2011-03-03 9:07 ` [PATCH] sched: QFQ - quick fair queue scheduler (v2) Eric Dumazet
2011-03-02 11:50 ` Patrick McHardy
2011-03-02 15:41 ` Eric Dumazet
2011-03-02 15:53 ` Eric Dumazet
2011-03-03 16:03 ` Eric Dumazet
2011-03-03 16:48 ` [PATCH] sched: QFQ - quick fair queue scheduler (v3) Stephen Hemminger
2011-03-03 22:28 ` Eric Dumazet
2011-03-03 22:59 ` Stephen Hemminger
2011-03-03 23:02 ` [PATCH] sched: QFQ - quick fair queue scheduler (v3.1) Stephen Hemminger
2011-03-03 23:12 ` Eric Dumazet
2011-03-04 0:03 ` [PATCH] sched: QFQ - quick fair queue scheduler (v3) Stephen Hemminger
2011-03-04 0:30 ` [PATCH] sched: QFQ - quick fair queue scheduler (v4) Stephen Hemminger
2011-03-04 6:50 ` Eric Dumazet
2011-03-04 17:17 ` Stephen Hemminger
2011-03-04 17:18 ` Stephen Hemminger
2011-03-04 17:20 ` QFQ debugfs Stephen Hemminger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1299140868.2456.35.camel@edumazet-laptop \
--to=eric.dumazet@gmail.com \
--cc=davem@davemloft.net \
--cc=fchecconi@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=paolo.valente@unimore.it \
--cc=rizzo@iet.unipi.it \
--cc=shemminger@vyatta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox