diff options
author | John W. Linville <linville@tuxdriver.com> | 2011-04-26 15:39:10 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-04-26 15:39:10 -0400 |
commit | 429576b97c623b9c4e3375fb7c37bce377f51e68 (patch) | |
tree | dc4fd40ae54d177ddb3cb3991e8c3ff019eef238 /net/bluetooth/hci_core.c | |
parent | 9835a30e980561082beb02ce724f6e555787bc19 (diff) | |
parent | 069f40fc07f6df3da325e7ea1698a0d6247983d5 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6
Diffstat (limited to 'net/bluetooth/hci_core.c')
-rw-r--r-- | net/bluetooth/hci_core.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c index a80bc1cdb35b..227bde39ee58 100644 --- a/net/bluetooth/hci_core.c +++ b/net/bluetooth/hci_core.c | |||
@@ -586,10 +586,8 @@ static int hci_dev_do_close(struct hci_dev *hdev) | |||
586 | hci_req_cancel(hdev, ENODEV); | 586 | hci_req_cancel(hdev, ENODEV); |
587 | hci_req_lock(hdev); | 587 | hci_req_lock(hdev); |
588 | 588 | ||
589 | /* Stop timer, it might be running */ | ||
590 | del_timer_sync(&hdev->cmd_timer); | ||
591 | |||
592 | if (!test_and_clear_bit(HCI_UP, &hdev->flags)) { | 589 | if (!test_and_clear_bit(HCI_UP, &hdev->flags)) { |
590 | del_timer_sync(&hdev->cmd_timer); | ||
593 | hci_req_unlock(hdev); | 591 | hci_req_unlock(hdev); |
594 | return 0; | 592 | return 0; |
595 | } | 593 | } |
@@ -628,6 +626,7 @@ static int hci_dev_do_close(struct hci_dev *hdev) | |||
628 | 626 | ||
629 | /* Drop last sent command */ | 627 | /* Drop last sent command */ |
630 | if (hdev->sent_cmd) { | 628 | if (hdev->sent_cmd) { |
629 | del_timer_sync(&hdev->cmd_timer); | ||
631 | kfree_skb(hdev->sent_cmd); | 630 | kfree_skb(hdev->sent_cmd); |
632 | hdev->sent_cmd = NULL; | 631 | hdev->sent_cmd = NULL; |
633 | } | 632 | } |