diff options
-rw-r--r-- | net/bluetooth/mgmt.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 5a866b65371c..98392d61b78f 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c | |||
@@ -4357,7 +4357,8 @@ static void set_bredr_scan(struct hci_request *req) | |||
4357 | */ | 4357 | */ |
4358 | write_fast_connectable(req, false); | 4358 | write_fast_connectable(req, false); |
4359 | 4359 | ||
4360 | if (test_bit(HCI_CONNECTABLE, &hdev->dev_flags)) | 4360 | if (test_bit(HCI_CONNECTABLE, &hdev->dev_flags) || |
4361 | !list_empty(&hdev->whitelist)) | ||
4361 | scan |= SCAN_PAGE; | 4362 | scan |= SCAN_PAGE; |
4362 | if (test_bit(HCI_DISCOVERABLE, &hdev->dev_flags)) | 4363 | if (test_bit(HCI_DISCOVERABLE, &hdev->dev_flags)) |
4363 | scan |= SCAN_INQUIRY; | 4364 | scan |= SCAN_INQUIRY; |
@@ -4471,7 +4472,8 @@ static int set_bredr(struct sock *sk, struct hci_dev *hdev, void *data, u16 len) | |||
4471 | 4472 | ||
4472 | hci_req_init(&req, hdev); | 4473 | hci_req_init(&req, hdev); |
4473 | 4474 | ||
4474 | if (test_bit(HCI_CONNECTABLE, &hdev->dev_flags)) | 4475 | if (test_bit(HCI_CONNECTABLE, &hdev->dev_flags) || |
4476 | !list_empty(&hdev->whitelist)) | ||
4475 | set_bredr_scan(&req); | 4477 | set_bredr_scan(&req); |
4476 | 4478 | ||
4477 | /* Since only the advertising data flags will change, there | 4479 | /* Since only the advertising data flags will change, there |