Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ip_tunnel: fix building with NET_IP_TUNNEL=m

When af_mpls is built-in but the tunnel support is a module,
we get a link failure:

net/mpls/af_mpls.o: In function `mpls_init':
af_mpls.c:(.init.text+0xdc): undefined reference to `ip_tunnel_encap_add_ops'

This adds a Kconfig statement to prevent the broken
configuration and force mpls to be a module as well in
this case.

Fixes: bdc476413dcd ("ip_tunnel: add mpls over gre support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Amine Kherbouche <amine.kherbouche@6wind.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Arnd Bergmann and committed by
David S. Miller
0eb16f82 08b49b94

+1
+1
net/mpls/Kconfig
··· 24 24 25 25 config MPLS_ROUTING 26 26 tristate "MPLS: routing support" 27 + depends on NET_IP_TUNNEL || NET_IP_TUNNEL=n 27 28 ---help--- 28 29 Add support for forwarding of mpls packets. 29 30