diff options
author | 2025-02-20 10:05:23 +0200 | |
---|---|---|
committer | 2025-02-21 16:08:48 -0800 | |
commit | ea8af1affdc07bcf62fcb02c94cf8f7c4ad8d498 (patch) | |
tree | 70158e6dc4490b6cf3f35b6c8a5a05e654c4c51d /net/core/fib_rules.c | |
parent | ipv6: fib_rules: Add DSCP mask matching (diff) | |
download | wireguard-linux-ea8af1affdc07bcf62fcb02c94cf8f7c4ad8d498.tar.xz wireguard-linux-ea8af1affdc07bcf62fcb02c94cf8f7c4ad8d498.zip |
net: fib_rules: Enable DSCP mask usage
Allow user space to configure FIB rules that match on DSCP with a mask,
now that support has been added to the IPv4 and IPv6 address families.
Reviewed-by: Petr Machata <petrm@nvidia.com>
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Guillaume Nault <gnault@redhat.com>
Link: https://patch.msgid.link/20250220080525.831924-5-idosch@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to '')
-rw-r--r-- | net/core/fib_rules.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/fib_rules.c b/net/core/fib_rules.c index 00e6fe79ecba..4bc64d912a1c 100644 --- a/net/core/fib_rules.c +++ b/net/core/fib_rules.c @@ -845,7 +845,7 @@ static const struct nla_policy fib_rule_policy[FRA_MAX + 1] = { [FRA_FLOWLABEL_MASK] = { .type = NLA_BE32 }, [FRA_SPORT_MASK] = { .type = NLA_U16 }, [FRA_DPORT_MASK] = { .type = NLA_U16 }, - [FRA_DSCP_MASK] = { .type = NLA_REJECT }, + [FRA_DSCP_MASK] = NLA_POLICY_MASK(NLA_U8, INET_DSCP_MASK >> 2), }; int fib_newrule(struct net *net, struct sk_buff *skb, struct nlmsghdr *nlh, |