summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net/bluetooth/bnep/sock.c4
-rw-r--r--net/bluetooth/cmtp/sock.c4
-rw-r--r--net/bluetooth/hidp/sock.c10
3 files changed, 9 insertions, 9 deletions
diff --git a/net/bluetooth/bnep/sock.c b/net/bluetooth/bnep/sock.c
index 9ebd3c64474d..81065e548a1f 100644
--- a/net/bluetooth/bnep/sock.c
+++ b/net/bluetooth/bnep/sock.c
@@ -94,7 +94,7 @@ static int bnep_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
return err;
if (nsock->sk->sk_state != BT_CONNECTED) {
- fput(nsock->file);
+ sockfd_put(nsock);
return -EBADFD;
}
@@ -103,7 +103,7 @@ static int bnep_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
if (copy_to_user(argp, &ca, sizeof(ca)))
err = -EFAULT;
} else
- fput(nsock->file);
+ sockfd_put(nsock);
return err;
diff --git a/net/bluetooth/cmtp/sock.c b/net/bluetooth/cmtp/sock.c
index 783edab12ce8..8c7f7bc4e0ba 100644
--- a/net/bluetooth/cmtp/sock.c
+++ b/net/bluetooth/cmtp/sock.c
@@ -88,7 +88,7 @@ static int cmtp_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
return err;
if (nsock->sk->sk_state != BT_CONNECTED) {
- fput(nsock->file);
+ sockfd_put(nsock);
return -EBADFD;
}
@@ -97,7 +97,7 @@ static int cmtp_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
if (copy_to_user(argp, &ca, sizeof(ca)))
err = -EFAULT;
} else
- fput(nsock->file);
+ sockfd_put(nsock);
return err;
diff --git a/net/bluetooth/hidp/sock.c b/net/bluetooth/hidp/sock.c
index 3292b956a7c4..f4dd02ca9a96 100644
--- a/net/bluetooth/hidp/sock.c
+++ b/net/bluetooth/hidp/sock.c
@@ -86,13 +86,13 @@ static int hidp_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
isock = sockfd_lookup(ca.intr_sock, &err);
if (!isock) {
- fput(csock->file);
+ sockfd_put(csock);
return err;
}
if (csock->sk->sk_state != BT_CONNECTED || isock->sk->sk_state != BT_CONNECTED) {
- fput(csock->file);
- fput(isock->file);
+ sockfd_put(csock);
+ sockfd_put(isock);
return -EBADFD;
}
@@ -101,8 +101,8 @@ static int hidp_sock_ioctl(struct socket *sock, unsigned int cmd, unsigned long
if (copy_to_user(argp, &ca, sizeof(ca)))
err = -EFAULT;
} else {
- fput(csock->file);
- fput(isock->file);
+ sockfd_put(csock);
+ sockfd_put(isock);
}
return err;