[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250220080525.831924-1-idosch@nvidia.com>
Date: Thu, 20 Feb 2025 10:05:19 +0200
From: Ido Schimmel <idosch@...dia.com>
To: <netdev@...r.kernel.org>
CC: <davem@...emloft.net>, <kuba@...nel.org>, <pabeni@...hat.com>,
<edumazet@...gle.com>, <horms@...nel.org>, <donald.hunter@...il.com>,
<dsahern@...nel.org>, <petrm@...dia.com>, <gnault@...hat.com>, Ido Schimmel
<idosch@...dia.com>
Subject: [PATCH net-next 0/6] net: fib_rules: Add DSCP mask support
In some deployments users would like to encode path information into
certain bits of the IPv6 flow label, the UDP source port and the DSCP
field and use this information to route packets accordingly.
Redirecting traffic to a routing table based on specific bits in the
DSCP field is not currently possible. Only exact match is currently
supported by FIB rules.
This patchset extends FIB rules to match on the DSCP field with an
optional mask.
Patches #1-#5 gradually extend FIB rules to match on the DSCP field with
an optional mask.
Patch #6 adds test cases for the new functionality.
iproute2 support can be found here [1].
[1] https://github.com/idosch/iproute2/tree/submit/fib_rule_mask_v1
Ido Schimmel (6):
net: fib_rules: Add DSCP mask attribute
ipv4: fib_rules: Add DSCP mask matching
ipv6: fib_rules: Add DSCP mask matching
net: fib_rules: Enable DSCP mask usage
netlink: specs: Add FIB rule DSCP mask attribute
selftests: fib_rule_tests: Add DSCP mask match tests
Documentation/netlink/specs/rt_rule.yaml | 5 ++
include/uapi/linux/fib_rules.h | 1 +
net/core/fib_rules.c | 1 +
net/ipv4/fib_rules.c | 47 +++++++++++++++++--
net/ipv6/fib6_rules.c | 45 +++++++++++++++++-
tools/testing/selftests/net/fib_rule_tests.sh | 38 +++++++++++++++
6 files changed, 132 insertions(+), 5 deletions(-)
--
2.48.1
Powered by blists - more mailing lists