Skip to content

Commit 1488af7

Browse files
committed
Bluetooth: hci_sync: Fix hci_resume_advertising_sync
hci_resume_advertising_sync is suppose to resume all instance paused by hci_pause_advertising_sync, this logic is used for procedures are only allowed when not advertising, but instance 0x00 was not being re-enabled. Fixes: ad383c2 ("Bluetooth: hci_sync: Enable advertising when LL privacy is enabled") Signed-off-by: Luiz Augusto von Dentz <[email protected]>
1 parent 1c5091a commit 1488af7

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

net/bluetooth/hci_sync.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2594,6 +2594,13 @@ static int hci_resume_advertising_sync(struct hci_dev *hdev)
25942594
hci_remove_ext_adv_instance_sync(hdev, adv->instance,
25952595
NULL);
25962596
}
2597+
2598+
/* If current advertising instance is set to instance 0x00
2599+
* then we need to re-enable it.
2600+
*/
2601+
if (!hdev->cur_adv_instance)
2602+
err = hci_enable_ext_advertising_sync(hdev,
2603+
hdev->cur_adv_instance);
25972604
} else {
25982605
/* Schedule for most recent instance to be restarted and begin
25992606
* the software rotation loop

0 commit comments

Comments
 (0)