From: David Ahern <dsahern@gmail.com>
To: netdev@vger.kernel.org
Cc: David Ahern <dsahern@gmail.com>
Subject: [PATCH net-next 1/2] net/ipv6: Handle onlink flag with multipath routes
Date: Tue, 13 Mar 2018 08:40:09 -0700 [thread overview]
Message-ID: <20180313154010.31623-2-dsahern@gmail.com> (raw)
In-Reply-To: <20180313154010.31623-1-dsahern@gmail.com>
For multipath routes the ONLINK flag is specified per nexthop in rtnh_flags
(as opposed to rtm_flags for unicast routes). Update ip6_route_multipath_add
to set fc_flags based on rtnh_flags.
Fixes: fc1e64e1092f ("net/ipv6: Add support for onlink flag")
Signed-off-by: David Ahern <dsahern@gmail.com>
---
net/ipv6/route.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/net/ipv6/route.c b/net/ipv6/route.c
index f0ae58424c45..b223dffa8521 100644
--- a/net/ipv6/route.c
+++ b/net/ipv6/route.c
@@ -4166,6 +4166,7 @@ static int ip6_route_multipath_add(struct fib6_config *cfg,
r_cfg.fc_encap_type = nla_get_u16(nla);
}
+ r_cfg.fc_flags |= (rtnh->rtnh_flags & RTNH_F_ONLINK);
rt = ip6_route_info_create(&r_cfg, extack);
if (IS_ERR(rt)) {
err = PTR_ERR(rt);
--
2.11.0
next prev parent reply other threads:[~2018-03-13 15:40 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-13 15:40 [PATCH net-next 0/2] net/ipv6: Handle onlink flag with multipath routes David Ahern
2018-03-13 15:40 ` David Ahern [this message]
2018-03-16 15:40 ` [PATCH net-next 1/2] " David Miller
2018-03-16 15:45 ` David Ahern
2018-03-16 16:38 ` David Miller
2018-03-16 18:18 ` David Ahern
2018-03-13 15:40 ` [PATCH net-next 2/2] selftests: Add multipath tests for onlink flag David Ahern
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=20180313154010.31623-2-dsahern@gmail.com \
--to=dsahern@gmail.com \
--cc=netdev@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.