Skip to content

Commit

Permalink
soc: nordic: nrf54l: Set SystemCoreClock using frequency from DT
Browse files Browse the repository at this point in the history
Use cpu clock source frequency as system core clock.

Signed-off-by: Krzysztof Chruściński <krzysztof.chruscinski@nordicsemi.no>
  • Loading branch information
nordic-krch committed Jan 17, 2025
1 parent 908a7eb commit 47c3a5b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions soc/nordic/nrf54l/soc.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@

#include <nrf_erratas.h>
#include <system_nrf54l.h>
#include <zephyr/drivers/clock_control/nrf_clock_control.h>

LOG_MODULE_REGISTER(soc, CONFIG_SOC_LOG_LEVEL);

Expand All @@ -43,9 +44,9 @@ LOG_MODULE_REGISTER(soc, CONFIG_SOC_LOG_LEVEL);
static int nordicsemi_nrf54l_init(void)
{
/* Update the SystemCoreClock global variable with current core clock
* retrieved from hardware state.
* retrieved from the DT.
*/
SystemCoreClockUpdate();
SystemCoreClock = NRF_PERIPH_GET_FREQUENCY(DT_NODELABEL(cpu));

#if defined(NRF_APPLICATION)
/* Enable ICACHE */
Expand Down

0 comments on commit 47c3a5b

Please sign in to comment.