tunnels: advertise link netns via netlink
Implement rtnl_link_ops->get_link_net() callback so that IFLA_LINK_NETNSID is added to rtnetlink messages. Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
d37512a277
commit
1728d4fabd
@@ -972,6 +972,14 @@ void ip_tunnel_dellink(struct net_device *dev, struct list_head *head)
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(ip_tunnel_dellink);
|
||||
|
||||
struct net *ip_tunnel_get_link_net(const struct net_device *dev)
|
||||
{
|
||||
struct ip_tunnel *tunnel = netdev_priv(dev);
|
||||
|
||||
return tunnel->net;
|
||||
}
|
||||
EXPORT_SYMBOL(ip_tunnel_get_link_net);
|
||||
|
||||
int ip_tunnel_init_net(struct net *net, int ip_tnl_net_id,
|
||||
struct rtnl_link_ops *ops, char *devname)
|
||||
{
|
||||
|
Reference in New Issue
Block a user