From: roopa <roopa@cumulusnetworks•com>
To: nicolas.dichtel@6wind•com
Cc: davem@davemloft•net, Mazziesaccount@gmail•com,
hannes@stressinduktion•org, kuznet@ms2•inr.ac.ru,
jmorris@namei•org, yoshfuji@linux-ipv6•org,
netdev@vger•kernel.org, Michal Kubecek <mkubecek@suse•cz>
Subject: Re: [PATCH net-next v2] ipv6: fix multipath route replace error recovery
Date: Mon, 07 Sep 2015 17:01:05 -0700 [thread overview]
Message-ID: <55EE2541.8030707@cumulusnetworks.com> (raw)
In-Reply-To: <55ED7D00.3050202@6wind.com>
On 9/7/15, 5:03 AM, Nicolas Dichtel wrote:
> The bug you're trying to fix has been introduced by the commit
> 51ebd3181572
> ("ipv6: add support of equal cost multipath (ECMP)").
> Commit 27596472473a ("ipv6: fix ECMP route replacement") didn't try to
> fix this
> problem.
The reason I say "27596472473a ("ipv6: fix ECMP route replacement") ",
has introduced the problem
i am trying to fix is because of the below change. The part where it
deletes all siblings of an existing route
diff --git a/net/ipv6/ip6_fib.c b/net/ipv6/ip6_fib.c
index 96dbfff..bde57b1 100644
--- a/net/ipv6/ip6_fib.c
+++ b/net/ipv6/ip6_fib.c
[..snip]
@@ -835,8 +851,27 @@ add:
info->nl_net->ipv6.rt6_stats->fib_route_nodes++;
fn->fn_flags |= RTN_RTINFO;
}
+ nsiblings = iter->rt6i_nsiblings;
fib6_purge_rt(iter, fn, info->nl_net);
rt6_release(iter);
+
+ if (nsiblings) {
+ /* Replacing an ECMP route, remove all siblings */
+ ins = &rt->dst.rt6_next;
+ iter = *ins;
+ while (iter) {
+ if (rt6_qualify_for_ecmp(iter)) {
+ *ins = iter->dst.rt6_next;
+ fib6_purge_rt(iter, fn,
info->nl_net);
+ rt6_release(iter);
+ nsiblings--;
+ } else {
+ ins = &iter->dst.rt6_next;
+ }
+ iter = *ins;
+ }
+ WARN_ON(nsiblings != 0);
+ }
}
return 0;
>
> Note that the first patch you submitted to fix this pb (cf
> http://patchwork.ozlabs.org/patch/362296/) was in June 2014, ie one
> year before
> the commit 27596472473a.
>
yes, i had submitted the patch you mention above to fix a slightly
different problem that existed then..which
was introduced by "51ebd3181572 ("ipv6: add support of equal cost
multipath (ECMP)")".
Commit "35f1b4e96b9258a3668872b1139c51e5a23eb876 ipv6: do not delete
previously existing ECMP routes if add fails"
subsequently fixed it.
Thanks,
Roopa
next prev parent reply other threads:[~2015-09-08 0:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-02 23:44 [PATCH net-next v2] ipv6: fix multipath route replace error recovery Roopa Prabhu
2015-09-04 8:12 ` Nicolas Dichtel
2015-09-06 20:46 ` roopa
2015-09-07 12:03 ` Nicolas Dichtel
2015-09-08 0:01 ` roopa [this message]
2015-09-08 9:33 ` Nicolas Dichtel
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=55EE2541.8030707@cumulusnetworks.com \
--to=roopa@cumulusnetworks$(echo .)com \
--cc=Mazziesaccount@gmail$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=hannes@stressinduktion$(echo .)org \
--cc=jmorris@namei$(echo .)org \
--cc=kuznet@ms2$(echo .)inr.ac.ru \
--cc=mkubecek@suse$(echo .)cz \
--cc=netdev@vger$(echo .)kernel.org \
--cc=nicolas.dichtel@6wind$(echo .)com \
--cc=yoshfuji@linux-ipv6$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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