diff options
author | Dave Young <hidave.darkstar@gmail.com> | 2007-12-30 04:17:47 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2007-12-30 04:17:47 +0100 |
commit | 38b7da09cfdb2202f08476d6fb22a47649a177ec (patch) | |
tree | 1f83cbc232b36282d7ed94104d8ae47fe9c55756 /net/bluetooth/hci_conn.c | |
parent | [TCP]: use non-delayed ACK for congestion control RTT (diff) | |
download | linux-38b7da09cfdb2202f08476d6fb22a47649a177ec.tar.xz linux-38b7da09cfdb2202f08476d6fb22a47649a177ec.zip |
[BLUETOOTH]: put_device before device_del fix
Because of workqueue delay, the put_device could be called before
device_del, so move it to del_conn.
Signed-off-by: Dave Young <hidave.darkstar@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bluetooth/hci_conn.c')
-rw-r--r-- | net/bluetooth/hci_conn.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c index 9483320f6dad..34d1a3c822bf 100644 --- a/net/bluetooth/hci_conn.c +++ b/net/bluetooth/hci_conn.c @@ -259,22 +259,14 @@ int hci_conn_del(struct hci_conn *conn) } tasklet_disable(&hdev->tx_task); - - hci_conn_del_sysfs(conn); - hci_conn_hash_del(hdev, conn); if (hdev->notify) hdev->notify(hdev, HCI_NOTIFY_CONN_DEL); - tasklet_enable(&hdev->tx_task); - skb_queue_purge(&conn->data_q); - + hci_conn_del_sysfs(conn); hci_dev_put(hdev); - /* will free via device release */ - put_device(&conn->dev); - return 0; } |