diff options
author | David Ward <david.ward@ll.mit.edu> | 2015-05-09 22:01:46 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-05-12 18:22:49 -0400 |
commit | a3eb95f891d6130b1fc03dd07a8b54cf0a5c8ab8 (patch) | |
tree | 0feb42c87e265a2f9ce8a144ed6c1d3d8a0bde81 /include/uapi | |
parent | 24e737c1ebacf0a19cb1d2671949de12b3361f4d (diff) | |
download | op-kernel-dev-a3eb95f891d6130b1fc03dd07a8b54cf0a5c8ab8.zip op-kernel-dev-a3eb95f891d6130b1fc03dd07a8b54cf0a5c8ab8.tar.gz |
net_sched: gred: add TCA_GRED_LIMIT attribute
In a GRED qdisc, if the default "virtual queue" (VQ) does not have drop
parameters configured, then packets for the default VQ are not subjected
to RED and are only dropped if the queue is larger than the net_device's
tx_queue_len. This behavior is useful for WRED mode, since these packets
will still influence the calculated average queue length and (therefore)
the drop probability for all of the other VQs. However, for some drivers
tx_queue_len is zero. In other cases the user may wish to make the limit
the same for all VQs (including the default VQ with no drop parameters).
This change adds a TCA_GRED_LIMIT attribute to set the GRED queue limit,
in bytes, during qdisc setup. (This limit is in bytes to be consistent
with the drop parameters.) The default limit is the same as for a bfifo
queue (tx_queue_len * psched_mtu). If the drop parameters of any VQ are
configured with a smaller limit than the GRED queue limit, that VQ will
still observe the smaller limit instead.
Signed-off-by: David Ward <david.ward@ll.mit.edu>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/uapi')
-rw-r--r-- | include/uapi/linux/pkt_sched.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/uapi/linux/pkt_sched.h b/include/uapi/linux/pkt_sched.h index 69d88b3..8d2530d 100644 --- a/include/uapi/linux/pkt_sched.h +++ b/include/uapi/linux/pkt_sched.h @@ -268,7 +268,8 @@ enum { TCA_GRED_STAB, TCA_GRED_DPS, TCA_GRED_MAX_P, - __TCA_GRED_MAX, + TCA_GRED_LIMIT, + __TCA_GRED_MAX, }; #define TCA_GRED_MAX (__TCA_GRED_MAX - 1) |