summaryrefslogtreecommitdiffstats
path: root/net/core
diff options
context:
space:
mode:
authorJoe Stringer <joe@wand.net.nz>2018-10-02 22:32:26 -0700
committerDaniel Borkmann <daniel@iogearbox.net>2018-10-04 10:32:56 +0200
commitd71019b54bff4b8f52903e354bf3b8cb2b4dfa75 (patch)
tree1da142e0c4a588b40dafae46f5f426080e3dea75 /net/core
parent33d9a7fd675678e7ea739ccb104abc1139caf19e (diff)
downloadblackbird-obmc-linux-d71019b54bff4b8f52903e354bf3b8cb2b4dfa75.tar.gz
blackbird-obmc-linux-d71019b54bff4b8f52903e354bf3b8cb2b4dfa75.zip
net: core: Fix build with CONFIG_IPV6=m
Stephen Rothwell reports the following link failure with IPv6 as module: x86_64-linux-gnu-ld: net/core/filter.o: in function `sk_lookup': (.text+0x19219): undefined reference to `__udp6_lib_lookup' Fix the build by only enabling the IPv6 socket lookup if IPv6 support is compiled into the kernel. Signed-off-by: Joe Stringer <joe@wand.net.nz> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'net/core')
-rw-r--r--net/core/filter.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/core/filter.c b/net/core/filter.c
index 591c698bc517..30c6b2d3ef16 100644
--- a/net/core/filter.c
+++ b/net/core/filter.c
@@ -4838,7 +4838,7 @@ struct sock *sk_lookup(struct net *net, struct bpf_sock_tuple *tuple,
sk = __udp4_lib_lookup(net, src4, tuple->ipv4.sport,
dst4, tuple->ipv4.dport,
dif, sdif, &udp_table, skb);
-#if IS_ENABLED(CONFIG_IPV6)
+#if IS_REACHABLE(CONFIG_IPV6)
} else {
struct in6_addr *src6 = (struct in6_addr *)&tuple->ipv6.saddr;
struct in6_addr *dst6 = (struct in6_addr *)&tuple->ipv6.daddr;
OpenPOWER on IntegriCloud