]> git.baikalelectronics.ru Git - kernel.git/commit
selftests: rtnetlink: Use more sensible tos values
authorGuillaume Nault <gnault@redhat.com>
Wed, 2 Feb 2022 15:24:21 +0000 (16:24 +0100)
committerJakub Kicinski <kuba@kernel.org>
Fri, 4 Feb 2022 03:11:21 +0000 (19:11 -0800)
commit194c4b03b9181f8efd54e86f7078a95daf273b54
tree195c9fc9d1e0f2d8266b4d9cc45e728c7286f462
parentfe31c1c8ab84d0e82d5e16c6f3f0a92fbcc01878
selftests: rtnetlink: Use more sensible tos values

Using tos 0x1 with 'ip route get <IPv4 address> ...' doesn't test much
of the tos option handling: 0x1 just sets an ECN bit, which is cleared
by inet_rtm_getroute() before doing the fib lookup. Let's use 0x10
instead, which is actually taken into account in the route lookup (and
is less surprising for the reader).

For consistency, use 0x10 for the IPv6 route lookup too (IPv6 currently
doesn't clear ECN bits, but might do so in the future).

Signed-off-by: Guillaume Nault <gnault@redhat.com>
Link: https://lore.kernel.org/r/d61119e68d01ba7ef3ba50c1345a5123a11de123.1643815297.git.gnault@redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/net/rtnetlink.sh