Skip to content

Bluetooth: Controller: can't cancel periodic advertising sync create betwee ll_sync_create and reception of AUX__ADV_IND with SyncInfo #45672

@ppryga-nordic

Description

@ppryga-nordic

Describe the bug

Current implementation of ll_sync_create_cancel does not allow to stop
synchronization after ull_sync_setup is called. When that is done,
sync->timeout_reload is not zero and the ll_sync_create_cancel will
return BT_HCI_ERR_CMD_DISALLOWED. That means the Controller is able to
cancel periodic advertising synchronization only in period between
call to ll_sync_create and reception of AUX_ADV_IND that has SyncInfo
field.

To Reproduce
Use Bluetooth sample applications that exercise periodic advertising and synchronization to the advertising.
In periodic advertising sample set long interval for periodic advertisements e.g. 4s.
Make bt_le_per_adv_sync_create_cancel global function.
In periodic advertising synchronizer add short sleep after call to bt_le_per_adv_sync_create and then add call to bt_le_per_adv_sync_create_cancel.
The latter call will cause a warning during compilation but it will create a valid binary.

Expected behavior
Synchronization should be cancelled successfully.

Impact
Low, I didn't observe the conformance tests failing due to this issue.
Nevertheless it should be fixed in case the conditions in conformance tests change.

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions