From 7515db8fa9edb6c46f54edf7ef4411ba1dd01534 Mon Sep 17 00:00:00 2001 From: Vinayak Kariappa Chettimada Date: Thu, 26 Mar 2020 14:18:26 +0530 Subject: [PATCH] Bluetooth: controller: Fix ticker ticks_current value Update the ticks_current value on last stopped ticker instance, so that when a new ticker instance is started the anchor ticks calculation uses the correct current tick with respect to supplied anchor ticks. Fixes #23805. Signed-off-by: Vinayak Kariappa Chettimada --- subsys/bluetooth/controller/ticker/ticker.c | 1 + 1 file changed, 1 insertion(+) diff --git a/subsys/bluetooth/controller/ticker/ticker.c b/subsys/bluetooth/controller/ticker/ticker.c index a598b304c50445..3f5766100563f8 100644 --- a/subsys/bluetooth/controller/ticker/ticker.c +++ b/subsys/bluetooth/controller/ticker/ticker.c @@ -2096,6 +2096,7 @@ static inline void ticker_job_compare_update(struct ticker_instance *instance, if (instance->ticker_id_head == TICKER_NULL) { if (cntr_stop() == 0) { instance->ticks_slot_previous = 0U; + instance->ticks_current = cntr_cnt_get(); } return; }