]> www.infradead.org Git - users/hch/misc.git/commit
ipv4: Prepare ip_rt_get_source() to future .flowi4_tos conversion.
authorGuillaume Nault <gnault@redhat.com>
Tue, 22 Oct 2024 09:48:23 +0000 (11:48 +0200)
committerJakub Kicinski <kuba@kernel.org>
Tue, 29 Oct 2024 18:21:06 +0000 (11:21 -0700)
commit85ef52e8693c4d3d23f33dc8007ebf11d5d4d4ce
treefcd9d5787e42b15632f9135b6f55c23fd7850af3
parent6ab04392dd087d896910dc618b4a14e54c58a499
ipv4: Prepare ip_rt_get_source() to future .flowi4_tos conversion.

Use ip4h_dscp() to get the DSCP from the IPv4 header, then convert the
dscp_t value to __u8 with inet_dscp_to_dsfield().

Then, when we'll convert .flowi4_tos to dscp_t, we'll just have to drop
the inet_dscp_to_dsfield() call.

Signed-off-by: Guillaume Nault <gnault@redhat.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Link: https://patch.msgid.link/0a13a200f31809841975e38633914af1061e0c04.1729530028.git.gnault@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/ipv4/route.c