From: Simon Mikuda <simon.mikuda@streamunlimited.com>
To: linux-bluetooth@vger.kernel.org
Cc: Simon Mikuda <simon.mikuda@streamunlimited.com>,
Marcel Holtmann <marcel@holtmann.org>,
Luiz Augusto von Dentz <luiz.dentz@gmail.com>
Subject: [PATCH] Bluetooth: hci_sync: Don't filter duplicates while a PA sync is pending
Date: Sun, 22 Nov 2026 21:13:28 +0100 [thread overview]
Message-ID: <20261122201328.2852883-1-simon.mikuda@streamunlimited.com> (raw)
To sync to a broadcast, the controller needs an extended advertisement of
the source after LE Periodic Advertising Create Sync, because that carries
the SyncInfo. Some controllers, for example an NXP one and an Intel
BE200, only use the SyncInfo of an advertisement they report to
the host. With the duplicates filter on, they report a source once per
scan. Passive scanning starts right before Create Sync, so when the source
is reported in between, its later advertisements are filtered out and the
sync waits until the host cancels it after 20 seconds:
21:59:14.147 > LE Extended Advertising Report 50:1E:2D:9F:95:23
21:59:14.149 < LE Periodic Advertising Create Sync
21:59:35.131 < LE Periodic Advertising Create Sync Cancel
21:59:35.132 > LE Periodic Advertising Sync Established
Status: Operation Cancelled by Host (0x44)
Turn the filter off while a PA sync is pending. The accept list limits the
reports to the source being synced.
Steps to reproduce:
1. Start a broadcast on another device.
2. Join it, leave and join again, repeatedly. Rarely the sync takes more
than 10 seconds, and until then there is no sound.
Fixes: eca0ae4aea66 ("Bluetooth: Add initial implementation of BIS connections")
Signed-off-by: Simon Mikuda <simon.mikuda@streamunlimited.com>
---
net/bluetooth/hci_sync.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/net/bluetooth/hci_sync.c b/net/bluetooth/hci_sync.c
index 638589f77081..88ce0ceef394 100644
--- a/net/bluetooth/hci_sync.c
+++ b/net/bluetooth/hci_sync.c
@@ -3645,6 +3645,12 @@ static int hci_passive_scan_sync(struct hci_dev *hdev)
filter_dups = LE_SCAN_FILTER_DUP_DISABLE;
}
+ /* The controller only syncs on a report it doesn't filter as a duplicate,
+ * and that report can come before the sync is created.
+ */
+ if (hci_dev_test_flag(hdev, HCI_PA_SYNC))
+ filter_dups = LE_SCAN_FILTER_DUP_DISABLE;
+
bt_dev_dbg(hdev, "LE passive scan with acceptlist = %d", filter_policy);
return hci_start_scan_sync(hdev, LE_SCAN_PASSIVE, interval, window,
base-commit: 4fe38719e6738feaa90486e36b0790dd5d960a96
--
2.43.0
next reply other threads:[~2026-11-22 20:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-22 20:13 Simon Mikuda [this message]
2026-11-22 22:47 ` Bluetooth: hci_sync: Don't filter duplicates while a PA sync is pending bluez.test.bot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261122201328.2852883-1-simon.mikuda@streamunlimited.com \
--to=simon.mikuda@streamunlimited.com \
--cc=linux-bluetooth@vger.kernel.org \
--cc=luiz.dentz@gmail.com \
--cc=marcel@holtmann.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox