History

net: fib_rules: Add DSCP selector attribute

The FIB rule TOS selector is implemented differently between IPv4 and IPv6. In IPv4 it is used to match on the three "Type of Services" bits specified in RFC 791, while in IPv6 is it is used to match on the six DSCP bits specified in RFC 2474. Add a new FIB rule attribute to allow matching on DSCP. The attribute will be used to implement a 'dscp' selector in ip-rule with a consistent behavior between IPv4 and IPv6. For now, set the type of the attribute to 'NLA_REJECT' so that user space will not be able to configure it. This restriction will be lifted once both IPv4 and IPv6 support the new attribute.

Ido Schimmel committed 2 years ago

Commit c951a291 parent 716425d2 files · +3 −1Browse files

Showing the changes to include/uapi (1 of 2 files). Show all

Unified · Split

include/uapi/linux/fib_rules.h+1−0
@@ -67,6 +67,7 @@ enum { · 66 unmodified lines
6767 FRA_IP_PROTO, /* ip proto */
6868 FRA_SPORT_RANGE, /* sport */
6969 FRA_DPORT_RANGE, /* dport */
70+ FRA_DSCP, /* dscp */
7071 __FRA_MAX
7172 };
7273

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t