Bluetooth: Controller: Fix assertion terminating Periodic Sync

Fix assertion due to changes introduced to support multiple
advertising chain reception.

Auxiliary context association with the Periodic Sync context
was not cleared due to which when terminating a Periodic
Synchronization triggered an assertion check, under race
conditions, detecting that the auxiliary context was already
released.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
This commit is contained in:
Vinayak Kariappa Chettimada 2025-02-07 19:16:13 +01:00 committed by Benjamin Cabé
parent 2461552e19
commit 3263729020

View File

@ -635,6 +635,9 @@ static void abort_cb(struct lll_prepare_param *prepare_param, void *param)
lll = prepare_param->param;
lll->skip_prepare += (lll->lazy_prepare + 1U);
/* Reset Sync context association with any Aux context as the chain reception is aborted. */
lll->lll_aux = NULL;
/* Extra done event, to check sync lost */
e = ull_event_done_extra_get();
LL_ASSERT(e);
@ -1185,6 +1188,9 @@ static void isr_rx_done_cleanup(struct lll_sync *lll, uint8_t crc_ok, bool sync_
{
struct event_done_extra *e;
/* Reset Sync context association with any Aux context as the chain reception is done. */
lll->lll_aux = NULL;
/* Calculate and place the drift information in done event */
e = ull_event_done_extra_get();
LL_ASSERT(e);