[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200921122216.v4.3.I21e5741249e78c560ca377499ba06b56c7214985@changeid>
Date: Mon, 21 Sep 2020 12:23:07 +0800
From: Howard Chung <howardchung@...gle.com>
To: linux-bluetooth@...r.kernel.org, marcel@...tmann.org,
luiz.dentz@...il.com
Cc: alainm@...omium.org, mcchou@...omium.org, mmandlik@...omium.orgi,
Howard Chung <howardchung@...gle.com>,
Manish Mandlik <mmandlik@...omium.org>,
"David S. Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>,
Johan Hedberg <johan.hedberg@...il.com>,
linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: [PATCH v4 3/4] Bluetooth: Handle active scan case
This patch adds code to handle the active scan during interleave
scan. The interleave scan will be canceled when users start active scan,
and it will be restarted after active scan stopped.
Signed-off-by: Howard Chung <howardchung@...gle.com>
Reviewed-by: Alain Michaud <alainm@...omium.org>
Reviewed-by: Manish Mandlik <mmandlik@...omium.org>
---
(no changes since v1)
net/bluetooth/hci_request.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/net/bluetooth/hci_request.c b/net/bluetooth/hci_request.c
index d9082019b6386..1fcf6736811e4 100644
--- a/net/bluetooth/hci_request.c
+++ b/net/bluetooth/hci_request.c
@@ -3085,8 +3085,10 @@ static int active_scan(struct hci_request *req, unsigned long opt)
* running. Thus, we should temporarily stop it in order to set the
* discovery scanning parameters.
*/
- if (hci_dev_test_flag(hdev, HCI_LE_SCAN))
+ if (hci_dev_test_flag(hdev, HCI_LE_SCAN)) {
hci_req_add_le_scan_disable(req, false);
+ cancel_interleave_scan(hdev);
+ }
/* All active scans will be done with either a resolvable private
* address (when privacy feature has been enabled) or non-resolvable
--
2.28.0.681.g6f77f65b4e-goog
Powered by blists - more mailing lists