[Devel] [PATCH RH7/RH8] ve/net: sit: enable in container

Vasily Averin vvs at virtuozzo.com
Mon Mar 29 15:47:54 MSK 2021


Currently, we fail to create sit interface inside container,
because it has neither NETIF_F_VIRTUAL nor NETIF_F_NETNS_LOCAL:

  ipip6_tunnel_ioctl
   ipip6_tunnel_locate
    ipip6_tunnel_create
     register_netdevice
      ve_is_dev_movable

Mark sit as NETIF_F_VIRTUAL to fix this issue.

https://jira.sw.ru/browse/PSBM-127315
Signed-off-by: Vasily Averin <vvs at virtuozzo.com>
---
 net/ipv6/sit.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/net/ipv6/sit.c b/net/ipv6/sit.c
index b25418369061..52b9e6a20429 100644
--- a/net/ipv6/sit.c
+++ b/net/ipv6/sit.c
@@ -1298,6 +1298,7 @@ static void ipip6_tunnel_setup(struct net_device *dev)
 	dev->addr_len		= 4;
 	dev->features		|= NETIF_F_LLTX;
 	dev->features		|= SIT_FEATURES;
+	dev->features		|= NETIF_F_VIRTUAL;
 	dev->hw_features	|= SIT_FEATURES;
 }
 
-- 
2.25.1



More information about the Devel mailing list