Subject: Re: [PATCH 2/3] NET: [SCHED] Qdisc changes and sch_rr added for multiqueue

From: Patrick McHardy <[email-masked]>
Date: Mon, 18 Jun 2007 22:54:41 +0200

Waskiewicz Jr, Peter P wrote:
>>>+	band = TC_H_MIN(band) - 1;
>>>+	if (band > q->bands) {
>>
>>You copied an off-by-one from an old sch_prio version here.
> 
> 
> Hmm.  This is the sch_prio from the first 2.6.23-dev tree.  I'll resync
> and make sure it's the correct one.

Current 2.6.22-rc and net-2.6.23 have

        if (band >= q->bands)

>>>+static int rr_tune(struct Qdisc *sch, struct rtattr *opt)
>>>+{
>>>+	struct rr_sched_data *q = qdisc_priv(sch);
>>>+	struct tc_rr_qopt *qopt = RTA_DATA(opt);
>>
>>
>>Nested attributes please, don't repeat sch_prio's mistake.
> 
> 
> I'm not sure I understand what you mean here about nested attributes.

Nested netlink attributes, like most qdisc use, instead of
struct tc_rr_qopt (or additionally). The way you've done
it makes it hard to add further attributes later.

BTw, couldn't you just merge sch_rr with prio? AFAICT you
only need a new dequeue function, a new struct Qdisc_ops
and a MODULE_ALIAS.