]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
Revert "Bluetooth: Move shutdown callback before flushing tx and rx queue"
authorSasha Levin <sashal@kernel.org>
Thu, 16 Sep 2021 01:15:41 +0000 (21:15 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 16 Sep 2021 10:30:15 +0000 (12:30 +0200)
This reverts commit 471128476819777a7b71f2b90bc868ccf74b185f.

Botched backport, dropping to rework for next release.

Reported-by: Pavel Machek <pavel@denx.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/bluetooth/hci_core.c

index bf1bb08b94aad5cc9bff7448ac896d985fb13d73..8d455c2321545792e1ceefd0c82b3af06ef6bba9 100644 (file)
@@ -1740,14 +1740,6 @@ int hci_dev_do_close(struct hci_dev *hdev)
        hci_request_cancel_all(hdev);
        hci_req_sync_lock(hdev);
 
-       if (!hci_dev_test_flag(hdev, HCI_UNREGISTER) &&
-           !hci_dev_test_flag(hdev, HCI_USER_CHANNEL) &&
-           test_bit(HCI_UP, &hdev->flags)) {
-               /* Execute vendor specific shutdown routine */
-               if (hdev->shutdown)
-                       hdev->shutdown(hdev);
-       }
-
        if (!test_and_clear_bit(HCI_UP, &hdev->flags)) {
                cancel_delayed_work_sync(&hdev->cmd_timer);
                hci_req_sync_unlock(hdev);