aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--include/net/ip6_fib.h1
-rw-r--r--include/net/ip6_route.h4
2 files changed, 3 insertions, 2 deletions
diff --git a/include/net/ip6_fib.h b/include/net/ip6_fib.h
index 2d2a468b3d6d..3b04b318cf13 100644
--- a/include/net/ip6_fib.h
+++ b/include/net/ip6_fib.h
@@ -126,6 +126,7 @@ struct rt6_exception {
struct fib6_nh {
struct in6_addr nh_gw;
+ bool fib_nh_has_gw;
struct net_device *nh_dev;
struct lwtunnel_state *nh_lwtstate;
diff --git a/include/net/ip6_route.h b/include/net/ip6_route.h
index 7ab119936e69..95cd8a2f6284 100644
--- a/include/net/ip6_route.h
+++ b/include/net/ip6_route.h
@@ -68,8 +68,8 @@ static inline bool rt6_need_strict(const struct in6_addr *daddr)
static inline bool rt6_qualify_for_ecmp(const struct fib6_info *f6i)
{
- return (f6i->fib6_flags & (RTF_GATEWAY|RTF_ADDRCONF|RTF_DYNAMIC)) ==
- RTF_GATEWAY;
+ return !(f6i->fib6_flags & (RTF_ADDRCONF|RTF_DYNAMIC)) &&
+ f6i->fib6_nh.fib_nh_has_gw;
}
void ip6_route_input(struct sk_buff *skb);