Commit 2baecda3 authored by Taehee Yoo's avatar Taehee Yoo Committed by David S. Miller

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: default avatarTaehee Yoo <ap420073@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c46a49a4
......@@ -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;
}
......
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