From: Hannes Frederic Sowa <hannes@stressinduktion.org>
To: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Cc: netdev@vger.kernel.org, yoshfuji@linux-ipv6.org,
petrus.lt@gmail.com, davem@davemloft.net
Subject: Re: [PATCH RFC] ipv6: fix route selection if kernel is not compiled with CONFIG_IPV6_ROUTER_PREF
Date: Fri, 12 Jul 2013 21:20:23 +0200 [thread overview]
Message-ID: <20130712192023.GP12611@order.stressinduktion.org> (raw)
In-Reply-To: <51E0527D.2030205@6wind.com>
On Fri, Jul 12, 2013 at 09:01:17PM +0200, Nicolas Dichtel wrote:
> Le 12/07/2013 18:19, Hannes Frederic Sowa a écrit :
> >On Fri, Jul 12, 2013 at 02:04:45PM +0200, Nicolas Dichtel wrote:
> >>It's possible to add a glue to check this counter when we play with these
> >>flags, but it's ugly.
> >>
> >>Maybe the check against RTF_EXPIRES is fundamentally wrong. Checking
> >>RTF_ADDRCONF|RTF_DYNAMIC should be enough, what do you think?
> >
> >Yes, this seems to be the best option now. I will audit the source if
> >RTF_ADDRCONF and RTF_DYNAMIC are immutable after dst construction and
> >if other errors could arise for that and would go with this solution then.
> >
> >What do you think about making ecmp routes explicit by adding RTF_ECMP
> >flag?
> Why not, but you will have to be careful on insertion and deletion. Next
> hop can be added one by one and deleted one by one.
Ok, we can have a look to do so in -next.
> >
> >>In another hand, we can discuss about the initial assumption, that was
> >>"only static routes are part of ECMP routes". I'm thinking of what are the
> >>consequence if we accept to accept all routes, without checking any flags.
> >
> >I don't have a good feeling about that. But I may be wrong.
> Same for me, but for now, I don't have any argument ;-) The above solution
> is probably the better way for now.
To go without RTF_EXPIRES seems the way to go. I still am unsure if we need to
propagate the RTF_DYNAMIC flag in case we update the expiration date on a
route.
--- a/net/ipv6/ip6_fib.c
+++ b/net/ipv6/ip6_fib.c
@@ -682,6 +682,7 @@ static int fib6_add_rt2node(struct fib6_node *fn, struct rt6_info *rt,
rt->rt6i_nsiblings = 0;
if (!(iter->rt6i_flags & RTF_EXPIRES))
return -EEXIST;
+ iter->rt6i_flags |= rt->rt6i_flags & RTF_DYNAMIC;
if (!(rt->rt6i_flags & RTF_EXPIRES))
rt6_clean_expires(iter);
else
I hope to have identified all possible site-effects later today.
Thanks,
Hannes
next prev parent reply other threads:[~2013-07-12 19:20 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-07 17:30 [PATCH RFC] ipv6: fix route selection if kernel is not compiled with CONFIG_IPV6_ROUTER_PREF Hannes Frederic Sowa
2013-07-09 21:57 ` Hannes Frederic Sowa
2013-07-10 7:54 ` Nicolas Dichtel
2013-07-10 9:28 ` Nicolas Dichtel
2013-07-10 10:53 ` Hannes Frederic Sowa
2013-07-10 12:22 ` Nicolas Dichtel
2013-07-10 13:21 ` Hannes Frederic Sowa
2013-07-10 14:10 ` Nicolas Dichtel
2013-07-10 15:20 ` Hannes Frederic Sowa
2013-07-10 15:59 ` Hannes Frederic Sowa
2013-07-10 16:35 ` Hannes Frederic Sowa
2013-07-11 8:07 ` Nicolas Dichtel
2013-07-10 21:21 ` Hannes Frederic Sowa
2013-07-11 8:04 ` Nicolas Dichtel
2013-07-11 10:24 ` Hannes Frederic Sowa
2013-07-11 14:46 ` Hannes Frederic Sowa
2013-07-11 14:57 ` Nicolas Dichtel
2013-07-12 8:51 ` Hannes Frederic Sowa
2013-07-12 12:04 ` Nicolas Dichtel
2013-07-12 16:19 ` Hannes Frederic Sowa
2013-07-12 19:01 ` Nicolas Dichtel
2013-07-12 19:20 ` Hannes Frederic Sowa [this message]
2013-07-12 21:48 ` Hannes Frederic Sowa
2013-07-10 11:15 ` Hannes Frederic Sowa
2013-07-10 11:40 ` Hannes Frederic Sowa
2013-07-10 12:08 ` Nicolas Dichtel
2013-07-10 13:17 ` Hannes Frederic Sowa
2013-07-10 13:49 ` Hannes Frederic Sowa
2013-07-10 14:30 ` Nicolas Dichtel
2013-07-10 14:34 ` Hannes Frederic Sowa
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=20130712192023.GP12611@order.stressinduktion.org \
--to=hannes@stressinduktion.org \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=nicolas.dichtel@6wind.com \
--cc=petrus.lt@gmail.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).