netdev
[Top] [All Lists]

Re: [PATCH] netem: account for packets in delayed queue in qlen

To: Stephen Hemminger <shemminger@xxxxxxxx>
Subject: Re: [PATCH] netem: account for packets in delayed queue in qlen
From: Patrick McHardy <kaber@xxxxxxxxx>
Date: Fri, 22 Apr 2005 01:39:32 +0200
Cc: "David S. Miller" <davem@xxxxxxxxxxxxx>, netdev@xxxxxxxxxxx
In-reply-to: <20050422092221.4950e23c@xxxxxxxxxxxxxxxxxxxxx>
References: <20050329152110.38d50653@xxxxxxxxxxxxxxxxx> <4252EB9D.9070305@xxxxxxxxx> <20050407120417.4297cd14@xxxxxxxxxxxxxxxxx> <42628300.9010007@xxxxxxxxx> <20050419110639.47767113@xxxxxxxxxxxxxxxxxxxxx> <42666098.5060409@xxxxxxxxx> <20050421132020.41858bc4@xxxxxxxxxxxxxxxxxxxxx> <426832E1.7020003@xxxxxxxxx> <20050422092221.4950e23c@xxxxxxxxxxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.7.6) Gecko/20050324 Debian/1.7.6-1
Stephen Hemminger wrote:
I'm thinking of changing enqueue (and maybe later dequeue) API to decouple
the qlen assumption.

Either:
        rc = qdisc->enqueue(skb, qdisc, &my->qlen)
or add NET_XMIT_DUPPED
        rc = qdisc->enqueue(skb, qdisc);
        if (rc < NET_XMIT_SUCCESS) {
                ++my->dropped;
        } else {
                my->qlen++;
                if (rc == NET_XMIT_DUPPED)
                        my->qlen++;
}

To be frank, I don't like either one. Both have the same problem
wrt. HFSC, the first solution requires changes all over the place,
the second one is unflexible and also requires lots of changes. I
don't see what could benefit from this API change besides netem,
so I'd vote to go with my proposed solution: store the parent
pointers in struct Qdisc, add code to walk up the tree and adjust
the qlen to netem, and fix up HFSC.

Regards
Patrick

<Prev in Thread] Current Thread [Next in Thread>