Skip to content

Commit

Permalink
compat: Always use own __ipv6_select_ident().
Browse files Browse the repository at this point in the history
If the ip fragmentation backport is enabled, we should always use our
own {,__}ipv6_select_ident(). This fixes the following issue on some
v3.19 kernels:

datapath/linux/ip6_output.c:93:12: error: conflicting types for
‘__ipv6_select_ident’
 static u32 __ipv6_select_ident(struct net *net, u32 hashrnd,

Reported-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: Joe Stringer <joe@ovn.org>
Acked-by: Pravin B Shelar <pshelar@nicira.com>
Tested-by: Simon Horman <simon.horman@netronome.com>
  • Loading branch information
joestringer committed Dec 19, 2015
1 parent 7d9cfd7 commit 69ad704
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions datapath/linux/compat/ip6_output.c
Expand Up @@ -90,7 +90,7 @@ static u32 rpl_ip_idents_reserve(u32 hash, int segs)
return atomic_add_return(segs + delta, p_id) - segs;
}

static u32 __ipv6_select_ident(struct net *net, u32 hashrnd,
static u32 rpl___ipv6_select_ident(struct net *net, u32 hashrnd,
const struct in6_addr *dst,
const struct in6_addr *src)
{
Expand All @@ -111,7 +111,6 @@ static u32 __ipv6_select_ident(struct net *net, u32 hashrnd,
return id;
}

/* XXX: Exported in 3.19. */
static __be32 rpl_ipv6_select_ident(struct net *net,
const struct in6_addr *daddr,
const struct in6_addr *saddr)
Expand All @@ -121,7 +120,7 @@ static __be32 rpl_ipv6_select_ident(struct net *net,

net_get_random_once(&ip6_idents_hashrnd, sizeof(ip6_idents_hashrnd));

id = __ipv6_select_ident(net, ip6_idents_hashrnd, daddr, saddr);
id = rpl___ipv6_select_ident(net, ip6_idents_hashrnd, daddr, saddr);
return htonl(id);
}

Expand Down

0 comments on commit 69ad704

Please sign in to comment.