--- jamal <[EMAIL PROTECTED]> wrote:

> You will always point to correctly initialized
> queues with any
> value of skb->priority.

Ok, to put it concretely:

Suppose we have prio configured thus:

tc qdisc add dev eth0 root handle 1: prio bands 4

This qdisc has 4 bands but it uses the default priomap
which mentions only bands 0-2. When prio_init() is
called it sets all bands to noop_qdisc.
Then it calls prio_tune(), which goes over the
prio2band[] array, and initializes the bands that
appear in the array. Since the array doesn't
contain the number 3, band 3 isn't initialized -- it's
still set to noop_qdisc, while the other 3 bands use
the default qdisc.

So, using CLASSIFY iptables target set to class 1:4
will make skb->priority point to band 3, which is
incorrectly initialized, even though we configured
prio to have bands 0-3. That's the bug.

Even if you consider such a use of the priority
illegitimate, the loop 
in prio_tune() still seems a little strange. Why does
it need to go over prio2band and access each band
multiple times instead of simply going linearly over
the requested number of bands?

Amnon





__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to