diff --git a/net/bluetooth/l2cap_sock.c b/net/bluetooth/l2cap_sock.c index 6db60946c627..68b57ef01c7d 100644 --- a/net/bluetooth/l2cap_sock.c +++ b/net/bluetooth/l2cap_sock.c @@ -1506,7 +1506,9 @@ static int l2cap_sock_recv_cb(struct l2cap_chan *chan, struct sk_buff *skb) err = __sock_queue_rcv_skb(sk, skb); + sock_hold(sk); l2cap_publish_rx_avail(chan); + sock_put(sk); /* For ERTM and LE, handle a skb that doesn't fit into the recv * buffer. This is important to do because the data frames