net: geneve: remove unused geneve_dev_create_fb

The only user was vport-geneve in openvswitch and now it is gone.

This also removes the last exported function in geneve module,
significantly reducing complexity of the locking analysis.

Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
Link: https://patch.msgid.link/20260804182049.2289754-5-i.maximets@ovn.org
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
Ilya Maximets
2026-08-04 20:20:38 +02:00
committed by Paolo Abeni
parent 2425eba0f8
commit e5ba332952
2 changed files with 0 additions and 54 deletions

View File

@@ -2670,55 +2670,6 @@ static struct rtnl_link_ops geneve_link_ops __read_mostly = {
.fill_info = geneve_fill_info,
};
struct net_device *geneve_dev_create_fb(struct net *net, const char *name,
u8 name_assign_type, u16 dst_port)
{
struct nlattr *tb[IFLA_MAX + 1];
struct net_device *dev;
LIST_HEAD(list_kill);
int err;
struct geneve_config cfg = {
.df = GENEVE_DF_UNSET,
.use_udp6_rx_checksums = true,
.ttl_inherit = false,
.collect_md = true,
.dualstack = true,
.port_min = 1,
.port_max = USHRT_MAX,
};
memset(tb, 0, sizeof(tb));
dev = rtnl_create_link(net, name, name_assign_type,
&geneve_link_ops, tb, NULL);
if (IS_ERR(dev))
return dev;
init_tnl_info(&cfg.info, dst_port);
err = geneve_configure(net, dev, NULL, &cfg);
if (err) {
free_netdev(dev);
return ERR_PTR(err);
}
/* openvswitch users expect packet sizes to be unrestricted,
* so set the largest MTU we can.
*/
err = geneve_change_mtu(dev, IP_MAX_MTU);
if (err)
goto err;
err = rtnl_configure_link(dev, NULL, 0, NULL);
if (err < 0)
goto err;
return dev;
err:
geneve_dellink(dev, &list_kill);
unregister_netdevice_many(&list_kill);
return ERR_PTR(err);
}
EXPORT_SYMBOL_GPL(geneve_dev_create_fb);
static int geneve_netdevice_event(struct notifier_block *unused,
unsigned long event, void *ptr)
{

View File

@@ -68,9 +68,4 @@ static inline bool netif_is_geneve(const struct net_device *dev)
!strcmp(dev->rtnl_link_ops->kind, "geneve");
}
#ifdef CONFIG_INET
struct net_device *geneve_dev_create_fb(struct net *net, const char *name,
u8 name_assign_type, u16 dst_port);
#endif /*ifdef CONFIG_INET */
#endif /*ifdef__NET_GENEVE_H */