This repository has been archived on 2026-03-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
ubports_kernel_google_msm/include/linux
Eric Dumazet 8af2a218de sch_red: Adaptative RED AQM
Adaptative RED AQM for linux, based on paper from Sally FLoyd,
Ramakrishna Gummadi, and Scott Shenker, August 2001 :

http://icir.org/floyd/papers/adaptiveRed.pdf

Goal of Adaptative RED is to make max_p a dynamic value between 1% and
50% to reach the target average queue : (max_th - min_th) / 2

Every 500 ms:
 if (avg > target and max_p <= 0.5)
  increase max_p : max_p += alpha;
 else if (avg < target and max_p >= 0.01)
  decrease max_p : max_p *= beta;

target :[min_th + 0.4*(min_th - max_th),
          min_th + 0.6*(min_th - max_th)].
alpha : min(0.01, max_p / 4)
beta : 0.9
max_P is a Q0.32 fixed point number (unsigned, with 32 bits mantissa)

Changes against our RED implementation are :

max_p is no longer a negative power of two (1/(2^Plog)), but a Q0.32
fixed point number, to allow full range described in Adatative paper.

To deliver a random number, we now use a reciprocal divide (thats really
a multiply), but this operation is done once per marked/droped packet
when in RED_BETWEEN_TRESH window, so added cost (compared to previous
AND operation) is near zero.

dump operation gives current max_p value in a new TCA_RED_MAX_P
attribute.

Example on a 10Mbit link :

tc qdisc add dev $DEV parent 1:1 handle 10: est 1sec 8sec red \
   limit 400000 min 30000 max 90000 avpkt 1000 \
   burst 55 ecn adaptative bandwidth 10Mbit

# tc -s -d qdisc show dev eth3
...
qdisc red 10: parent 1:1 limit 400000b min 30000b max 90000b ecn
adaptative ewma 5 max_p=0.113335 Scell_log 15
 Sent 50414282 bytes 34504 pkt (dropped 35, overlimits 1392 requeues 0)
 rate 9749Kbit 831pps backlog 72056b 16p requeues 0
  marked 1357 early 35 pdrop 0 other 0

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-12-08 19:52:43 -05:00
..
2011-11-27 17:17:04 -05:00
2011-11-07 09:11:16 -08:00
2011-11-22 16:43:32 -05:00
2011-11-02 16:07:03 -07:00
2011-10-26 15:43:25 -04:00
2011-11-16 09:21:50 +01:00
2011-09-27 09:25:02 +01:00
2011-10-31 17:30:44 -07:00
2011-11-02 12:53:43 +01:00
2011-11-07 23:54:53 +01:00
2011-10-31 20:19:04 +00:00
2011-11-26 14:59:39 -05:00
2011-11-16 17:43:08 -05:00
2011-09-14 15:24:51 -04:00
2011-11-16 22:00:34 -05:00
2011-11-23 11:33:07 +01:00
2011-11-16 18:16:38 -05:00
2011-11-13 16:10:10 -05:00
2011-09-27 18:08:04 +02:00
2011-11-13 16:10:10 -05:00
2011-09-25 19:52:59 +03:00
2011-09-16 19:20:20 -04:00
2011-11-02 16:06:57 -07:00
2011-11-02 16:06:58 -07:00
2011-11-14 00:47:54 -05:00
2011-10-31 14:03:22 +01:00
2011-12-08 19:52:43 -05:00
2011-11-02 16:07:02 -07:00
2011-11-29 11:59:50 +00:00
2011-12-04 13:20:39 -05:00
2011-12-06 13:58:01 -05:00
2011-10-31 17:30:47 -07:00
2011-10-31 17:30:44 -07:00
2011-11-02 16:07:02 -07:00
2011-10-03 14:01:21 -04:00
2011-11-02 16:07:02 -07:00
2011-09-14 15:24:51 -04:00