net: sched: RED: Introduce an ECN nodrop mode
authorPetr Machata <petrm@mellanox.com>
Thu, 12 Mar 2020 23:10:57 +0000 (01:10 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sun, 15 Mar 2020 04:03:46 +0000 (21:03 -0700)
commit0a7fad2376ba6b37c6b1a1072ed2a2381d82cd18
treececaf961e1015055ee4f9912de73fbd5d04f0722
parent14bc175d9c885c86239de3d730eea85ad67bfe7b
net: sched: RED: Introduce an ECN nodrop mode

When the RED Qdisc is currently configured to enable ECN, the RED algorithm
is used to decide whether a certain SKB should be marked. If that SKB is
not ECN-capable, it is early-dropped.

It is also possible to keep all traffic in the queue, and just mark the
ECN-capable subset of it, as appropriate under the RED algorithm. Some
switches support this mode, and some installations make use of it.

To that end, add a new RED flag, TC_RED_NODROP. When the Qdisc is
configured with this flag, non-ECT traffic is enqueued instead of being
early-dropped.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/pkt_cls.h
include/net/red.h
include/uapi/linux/pkt_sched.h
net/sched/sch_red.c