diff options
author | Taehee Yoo <ap420073@gmail.com> | 2020-03-08 04:19:30 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-03-09 07:22:29 +0300 |
commit | 2baecda37f4ef4414be15452a333fe4fd13c0df3 (patch) | |
tree | 54bb67e486613dbd525297cfb46b0c8912ca394b /drivers/net/bareudp.c | |
parent | c46a49a45c865350d6051df555034b86a2ac72ff (diff) | |
download | linux-2baecda37f4ef4414be15452a333fe4fd13c0df3.tar.xz |
bareudp: remove unnecessary udp_encap_enable() in bareudp_socket_create()
In the current code, udp_encap_enable() is called in
bareudp_socket_create().
But, setup_udp_tunnel_sock() internally calls udp_encap_enable().
So, udp_encap_enable() is unnecessary.
Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bareudp.c')
-rw-r--r-- | drivers/net/bareudp.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/net/bareudp.c b/drivers/net/bareudp.c index c9d0d68467f7..71a2f480f70e 100644 --- a/drivers/net/bareudp.c +++ b/drivers/net/bareudp.c @@ -250,9 +250,6 @@ static int bareudp_socket_create(struct bareudp_dev *bareudp, __be16 port) tunnel_cfg.encap_destroy = NULL; setup_udp_tunnel_sock(bareudp->net, sock, &tunnel_cfg); - if (sock->sk->sk_family == AF_INET6) - udp_encap_enable(); - rcu_assign_pointer(bareudp->sock, sock); return 0; } |