Commit 61ee4137 authored by YueHaibing's avatar YueHaibing Committed by Steffen Klassert

ip_vti: Fix unused variable warning

If CONFIG_INET_XFRM_TUNNEL is set but CONFIG_IPV6 is n,

net/ipv4/ip_vti.c:493:27: warning: 'vti_ipip6_handler' defined but not used [-Wunused-variable]
Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Signed-off-by: default avatarSteffen Klassert <steffen.klassert@secunet.com>
parent 1c3b63f1
...@@ -490,6 +490,7 @@ static struct xfrm_tunnel vti_ipip_handler __read_mostly = { ...@@ -490,6 +490,7 @@ static struct xfrm_tunnel vti_ipip_handler __read_mostly = {
.priority = 0, .priority = 0,
}; };
#if IS_ENABLED(CONFIG_IPV6)
static struct xfrm_tunnel vti_ipip6_handler __read_mostly = { static struct xfrm_tunnel vti_ipip6_handler __read_mostly = {
.handler = vti_rcv_tunnel, .handler = vti_rcv_tunnel,
.cb_handler = vti_rcv_cb, .cb_handler = vti_rcv_cb,
...@@ -497,6 +498,7 @@ static struct xfrm_tunnel vti_ipip6_handler __read_mostly = { ...@@ -497,6 +498,7 @@ static struct xfrm_tunnel vti_ipip6_handler __read_mostly = {
.priority = 0, .priority = 0,
}; };
#endif #endif
#endif
static int __net_init vti_init_net(struct net *net) static int __net_init vti_init_net(struct net *net)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment