Re: [PATCH net-next] netem: fix classful handling
From: Stephen Hemminger <hidden>
Date: 2011-12-29 06:17:36
On Thu, 29 Dec 2011 05:26:00 +0100 Eric Dumazet [off-list ref] wrote:
Commit 10f6dfcfde (Revert "sch_netem: Remove classful functionality") reintroduced classful functionality to netem, but broke basic netem behavior : netem uses an t(ime)fifo queue, and store timestamps in skb->cb[] If qdisc is changed, time constraints are not respected and other qdisc can destroy skb->cb[] and block netem at dequeue time. Fix this by always using internal tfifo, and optionally attach a child qdisc to netem. Example of use : DEV=eth3 tc qdisc del dev $DEV root tc qdisc add dev $DEV root handle 30: est 1sec 8sec netem delay 20ms 10ms tc qdisc add dev $DEV parent 30:0 sfq
Does it work with TBF which is a more useful option? Also, the whole tfifo idea is only to support the wierd idea that if doing random delay that packets should get reordered based on the results of the random value; it was an behavior some users wanted because that is what NISTnet did.