From: David Ahern <dsahern@gmail.com>
To: Ido Schimmel <idosch@mellanox.com>, netdev@vger.kernel.org
Cc: davem@davemloft.net, roopa@cumulusnetworks.com,
nicolas.dichtel@6wind.com, weiwan@google.com, kafai@fb.com,
yoshfuji@linux-ipv6.org, mlxsw@mellanox.com
Subject: Re: [PATCH net-next 00/18] ipv6: Align nexthop behaviour with IPv4
Date: Sun, 7 Jan 2018 10:20:11 -0700 [thread overview]
Message-ID: <5c10b955-161d-9cb1-edd1-7a49d88e46ad@gmail.com> (raw)
In-Reply-To: <20180107104518.31693-1-idosch@mellanox.com>
On 1/7/18 3:45 AM, Ido Schimmel wrote:
> This set tries to eliminate some differences between IPv4's and IPv6's
> treatment of nexthops. These differences are most likely a side effect
> of IPv6's data structures (specifically 'rt6_info') that incorporate
> both the route and the nexthop and the late addition of ECMP support in
> commit 51ebd3181572 ("ipv6: add support of equal cost multipath
> (ECMP)").
>
> IPv4 and IPv6 do not react the same to certain netdev events. For
> example, upon carrier change affected IPv4 nexthops are marked using the
> RTNH_F_LINKDOWN flag and the nexthop group is rebalanced accordingly.
> IPv6 on the other hand, does nothing which forces us to perform a
> carrier check during route lookup and dump. This makes it difficult to
> introduce features such as non-equal-cost multipath that are built on
> top of this set [1].
>
> In addition, when a netdev is put administratively down IPv4 nexthops
> are marked using the RTNH_F_DEAD flag, whereas IPv6 simply flushes all
> the routes using these nexthops. To be consistent with IPv4, multipath
> routes should only be flushed when all nexthops in the group are
> considered dead.
>
> The first 12 patches introduce non-functional changes that store the
> RTNH_F_DEAD and RTNH_F_LINKDOWN flags in IPv6 routes based on netdev
> events, in a similar fashion to IPv4. This allows us to remove the
> carrier check performed during route lookup and dump.
>
> The next three patches make sure we only flush a multipath route when
> all of its nexthops are dead.
>
> Last three patches add test cases for IPv4/IPv6 FIB. These verify that
> both address families react similarly to netdev events.
>
> Finally, this series also serves as a good first step towards David
> Ahern's goal of treating nexthops as standalone objects [2], as it makes
> the code more in line with IPv4 where the nexthop and the nexthop group
> are separate objects from the route itself.
>
> 1. https://github.com/idosch/linux/tree/ipv6-nexthops
> 2. http://vger.kernel.org/netconf2017_files/nexthop-objects.pdf
>
Thanks for working on this - and creating the test cases.
One of many follow on changes that would be beneficial is to remove the
idev dereference in the hot path to check the
ignore_routes_with_linkdown sysctl.
next prev parent reply other threads:[~2018-01-07 17:20 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-07 10:45 [PATCH net-next 00/18] ipv6: Align nexthop behaviour with IPv4 Ido Schimmel
2018-01-07 10:45 ` [PATCH net-next 01/18] ipv6: Remove redundant route flushing during namespace dismantle Ido Schimmel
2018-01-07 16:53 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 02/18] ipv6: Mark dead nexthops with appropriate flags Ido Schimmel
2018-01-07 16:54 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 03/18] ipv6: Clear nexthop flags upon netdev up Ido Schimmel
2018-01-07 16:54 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 04/18] ipv6: Prepare to handle multiple netdev events Ido Schimmel
2018-01-07 16:55 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 05/18] ipv6: Set nexthop flags upon carrier change Ido Schimmel
2018-01-07 16:56 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 06/18] ipv6: Set nexthop flags during route creation Ido Schimmel
2018-01-07 16:58 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 07/18] ipv6: Check nexthop flags during route lookup instead of carrier Ido Schimmel
2018-01-07 16:59 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 08/18] ipv6: Check nexthop flags in route dump " Ido Schimmel
2018-01-07 17:01 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 09/18] ipv6: Ignore dead routes during lookup Ido Schimmel
2018-01-07 17:02 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 10/18] ipv6: Report dead flag during route dump Ido Schimmel
2018-01-07 17:02 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 11/18] ipv6: Add explicit flush indication to routes Ido Schimmel
2018-01-07 17:03 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 12/18] ipv6: Teach tree walker to skip multipath routes Ido Schimmel
2018-01-07 17:04 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 13/18] ipv6: Export sernum update function Ido Schimmel
2018-01-07 17:04 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 14/18] ipv6: Take table lock outside of " Ido Schimmel
2018-01-07 17:05 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 15/18] ipv6: Flush multipath routes when all siblings are dead Ido Schimmel
2018-01-07 17:08 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 16/18] selftests: fib_tests: Add test cases for IPv4/IPv6 FIB Ido Schimmel
2018-01-07 17:15 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 17/18] selftests: fib_tests: Add test cases for netdev down Ido Schimmel
2018-01-07 17:15 ` David Ahern
2018-01-07 10:45 ` [PATCH net-next 18/18] selftests: fib_tests: Add test cases for netdev carrier change Ido Schimmel
2018-01-07 17:16 ` David Ahern
2018-01-07 17:20 ` David Ahern [this message]
2018-01-09 8:04 ` [PATCH net-next 00/18] ipv6: Align nexthop behaviour with IPv4 Ido Schimmel
2018-01-10 4:41 ` David Ahern
2018-01-08 2:30 ` David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5c10b955-161d-9cb1-edd1-7a49d88e46ad@gmail.com \
--to=dsahern@gmail.com \
--cc=davem@davemloft.net \
--cc=idosch@mellanox.com \
--cc=kafai@fb.com \
--cc=mlxsw@mellanox.com \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.com \
--cc=roopa@cumulusnetworks.com \
--cc=weiwan@google.com \
--cc=yoshfuji@linux-ipv6.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).