Bluetooth: Fix remote name event return directly.
Subsystems (2)
PATCH v2 1/1 Bluetooth: Fix remote name event return directly.
From: Wesley Kuo <[email protected]>
This patch fixes hci_remote_name_evt dose not resolve name during discovery status is RESOLVING. Before simultaneous dual mode scan enabled, hci_check_pending_name will set discovery status to STOPPED eventually.
Signed-off-by Wesley Kuo <[email protected]>
--- net/bluetooth/hci_core.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
net/bluetooth/hci_core.c +4 -2
@@ -2853,9 +2853,11 @@ static void le_scan_disable_work_complete(struct hci_dev *hdev, u8 status,* state. If we were running both LE and BR/EDR inquiry * simultaneously, and BR/EDR inquiry is already * finished, stop discovery, otherwise BR/EDR inquiry -* will stop discovery when finished. +* will stop discovery when finished. If we will resolve +* remote device name, do not change discovery state. */ -if (!test_bit (HCI_INQUIRY , &hdev->flags)) +if (!test_bit (HCI_INQUIRY , &hdev->flags) && + hdev->discovery.state !=DISCOVERY_RESOLVING )hci_discovery_set_state (hdev,DISCOVERY_STOPPED ); }else {
Signature · 1 line
1.7.9.5
Marcel Holtmann
maintainerHi Wesley,
Quoted 8 lines
This patch fixes
hci_remote_name_evtdose not resolve name during discovery status is RESOLVING. Before simultaneous dual mode scan enabled,hci_check_pending_namewill set discovery status to STOPPED eventually.Signed-off-by Wesley Kuo <[email protected]>---
net/bluetooth/hci_core.c| 6 ++++--1 file changed, 4 insertions(+), 2 deletions(-)
patch has been applied to bluetooth tree.
Regards
Marcel