Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions drivers/clock_control/clock_control_nrf.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,14 @@
#define INF(dev, subsys, ...) CLOCK_LOG(INF, dev, subsys, __VA_ARGS__)
#define DBG(dev, subsys, ...) CLOCK_LOG(DBG, dev, subsys, __VA_ARGS__)

#if defined(NRF54L05_XXAA) || defined(NRF54L10_XXAA) || defined(NRF54L15_XXAA)
#if NRFX_RELEASE_VER_AT_LEAST(3, 11, 0)
#error "Remove workaround for XOSTART as it is already done in the nrfx clock"
#endif

#define USE_WORKAROUND_FOR_CLOCK_XOSTART_ANOMALY 1
#endif

/* Clock subsys structure */
struct nrf_clock_control_sub_data {
clock_control_cb_t cb;
Expand Down Expand Up @@ -220,6 +228,9 @@
hf_start_tstamp = k_uptime_get();
}

#ifdef USE_WORKAROUND_FOR_CLOCK_XOSTART_ANOMALY
nrf_clock_task_trigger(NRF_CLOCK, NRF_CLOCK_TASK_PLLSTART);
#endif
nrfx_clock_hfclk_start();
}

Expand All @@ -230,6 +241,9 @@
}

nrfx_clock_hfclk_stop();
#ifdef USE_WORKAROUND_FOR_CLOCK_XOSTART_ANOMALY
nrf_clock_task_trigger(NRF_CLOCK, NRF_CLOCK_TASK_PLLSTOP);
#endif
}

#if NRF_CLOCK_HAS_HFCLK192M
Expand Down Expand Up @@ -622,6 +636,11 @@
__ASSERT_NO_MSG(false);
}
break;
case NRFX_CLOCK_EVT_PLL_STARTED:
{
/* unhandled event */

Check notice on line 641 in drivers/clock_control/clock_control_nrf.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

You may want to run clang-format on this change

drivers/clock_control/clock_control_nrf.c:641 - case NRFX_CLOCK_EVT_PLL_STARTED: - { + case NRFX_CLOCK_EVT_PLL_STARTED: {

Check notice on line 641 in drivers/clock_control/clock_control_nrf.c

View workflow job for this annotation

GitHub Actions / Run compliance checks on patch series (PR)

You may want to run clang-format on this change

drivers/clock_control/clock_control_nrf.c:641 - case NRFX_CLOCK_EVT_PLL_STARTED: - { + case NRFX_CLOCK_EVT_PLL_STARTED: {
break;
}
default:
__ASSERT_NO_MSG(0);
break;
Expand Down
Loading