diff options
Diffstat (limited to 'net/bluetooth/l2cap_sock.c')
-rw-r--r-- | net/bluetooth/l2cap_sock.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/net/bluetooth/l2cap_sock.c b/net/bluetooth/l2cap_sock.c index 7f9704993b74..141e7b058b7e 100644 --- a/net/bluetooth/l2cap_sock.c +++ b/net/bluetooth/l2cap_sock.c | |||
@@ -43,6 +43,12 @@ static void l2cap_sock_init(struct sock *sk, struct sock *parent); | |||
43 | static struct sock *l2cap_sock_alloc(struct net *net, struct socket *sock, | 43 | static struct sock *l2cap_sock_alloc(struct net *net, struct socket *sock, |
44 | int proto, gfp_t prio); | 44 | int proto, gfp_t prio); |
45 | 45 | ||
46 | bool l2cap_is_socket(struct socket *sock) | ||
47 | { | ||
48 | return sock && sock->ops == &l2cap_sock_ops; | ||
49 | } | ||
50 | EXPORT_SYMBOL(l2cap_is_socket); | ||
51 | |||
46 | static int l2cap_sock_bind(struct socket *sock, struct sockaddr *addr, int alen) | 52 | static int l2cap_sock_bind(struct socket *sock, struct sockaddr *addr, int alen) |
47 | { | 53 | { |
48 | struct sock *sk = sock->sk; | 54 | struct sock *sk = sock->sk; |