aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWesley Kuo <wesley.kuo@intel.com>2015-05-12 22:33:15 -0400
committerMarcel Holtmann <marcel@holtmann.org>2015-05-14 04:35:04 -0400
commit177d0506a911eb60b38b172215df5325ed94fa64 (patch)
tree8eb0f6d3eece488a002cc491f39456b57b9ea315
parentec0810d2ac1c932dad48f45da67e3adc5c5449a1 (diff)
Bluetooth: Fix remote name event return directly.
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 <wesley.kuo@intel.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
-rw-r--r--net/bluetooth/hci_core.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/net/bluetooth/hci_core.c b/net/bluetooth/hci_core.c
index 4663c3dad3f5..c4802f3bd4c5 100644
--- a/net/bluetooth/hci_core.c
+++ b/net/bluetooth/hci_core.c
@@ -2854,9 +2854,11 @@ static void le_scan_disable_work_complete(struct hci_dev *hdev, u8 status,
2854 * state. If we were running both LE and BR/EDR inquiry 2854 * state. If we were running both LE and BR/EDR inquiry
2855 * simultaneously, and BR/EDR inquiry is already 2855 * simultaneously, and BR/EDR inquiry is already
2856 * finished, stop discovery, otherwise BR/EDR inquiry 2856 * finished, stop discovery, otherwise BR/EDR inquiry
2857 * will stop discovery when finished. 2857 * will stop discovery when finished. If we will resolve
2858 * remote device name, do not change discovery state.
2858 */ 2859 */
2859 if (!test_bit(HCI_INQUIRY, &hdev->flags)) 2860 if (!test_bit(HCI_INQUIRY, &hdev->flags) &&
2861 hdev->discovery.state != DISCOVERY_RESOLVING)
2860 hci_discovery_set_state(hdev, 2862 hci_discovery_set_state(hdev,
2861 DISCOVERY_STOPPED); 2863 DISCOVERY_STOPPED);
2862 } else { 2864 } else {