Commit 6d9746f6 authored by David S. Miller's avatar David S. Miller

[IPV6]: Kill spurious module_{get,put}().

parent 0ebd8fff
......@@ -111,7 +111,6 @@ static void inet6_sock_destruct(struct sock *sk)
#ifdef INET_REFCNT_DEBUG
atomic_dec(&inet6_sock_nr);
#endif
module_put(THIS_MODULE);
}
static __inline__ kmem_cache_t *inet6_sk_slab(int protocol)
......@@ -243,11 +242,6 @@ static int inet6_create(struct socket *sock, int protocol)
atomic_inc(&inet6_sock_nr);
atomic_inc(&inet_sock_nr);
#endif
if (!try_module_get(THIS_MODULE)) {
inet_sock_release(sk);
return -EBUSY;
}
if (inet->num) {
/* It assumes that any protocol which allows
* the user to assign a number at socket
......@@ -259,7 +253,6 @@ static int inet6_create(struct socket *sock, int protocol)
if (sk->prot->init) {
int err = sk->prot->init(sk);
if (err != 0) {
module_put(THIS_MODULE);
inet_sock_release(sk);
return err;
}
......
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