From: Andrei Emeltchenko Date: Thu, 25 Oct 2012 12:20:51 +0000 (+0300) Subject: Bluetooth: Add put(hcon) when deleting hchan X-Git-Tag: v3.8-rc1~139^2~174^2^2~130^2~16 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=e9b02748ffc043e8a36f7893bbf58bb886f0b7e4;p=linux.git Bluetooth: Add put(hcon) when deleting hchan When refcnt reaches zero disconnect timeout will run and hci_conn will be disconnected. Signed-off-by: Andrei Emeltchenko Acked-by: Marcel Holtmann Signed-off-by: Gustavo Padovan --- diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c index dc331ceca471..25bfce0666eb 100644 --- a/net/bluetooth/hci_conn.c +++ b/net/bluetooth/hci_conn.c @@ -980,6 +980,8 @@ void hci_chan_del(struct hci_chan *chan) synchronize_rcu(); + hci_conn_put(conn); + skb_queue_purge(&chan->data_q); kfree(chan); }