diff --git a/subsys/mpsl/init/mpsl_init.c b/subsys/mpsl/init/mpsl_init.c index 669d21f7bd38..d1409d21097f 100644 --- a/subsys/mpsl/init/mpsl_init.c +++ b/subsys/mpsl/init/mpsl_init.c @@ -15,6 +15,9 @@ #include #include "multithreading_lock.h" #include +#if IS_ENABLED(CONFIG_SOC_COMPATIBLE_NRF54LX) +#include +#endif #if defined(CONFIG_NRFX_DPPI) #include #endif @@ -395,7 +398,8 @@ static int32_t mpsl_lib_init_internal(void) mpsl_clock_hfclk_latency_set(CONFIG_MPSL_HFCLK_LATENCY); - if (IS_ENABLED(CONFIG_SOC_NRF_FORCE_CONSTLAT)) { + if (IS_ENABLED(CONFIG_SOC_NRF_FORCE_CONSTLAT) && + !IS_ENABLED(CONFIG_SOC_COMPATIBLE_NRF54LX)) { mpsl_pan_rfu(); } @@ -509,6 +513,26 @@ int32_t mpsl_lib_uninit(void) #endif /* IS_ENABLED(CONFIG_MPSL_DYNAMIC_INTERRUPTS) */ } +#if defined(CONFIG_SOC_COMPATIBLE_NRF54LX) +void mpsl_constlat_request_callback(void) +{ +#if defined(CONFIG_NRFX_POWER) + nrfx_power_constlat_mode_request(); +#else + nrf_power_task_trigger(NRF_POWER, NRF_POWER_TASK_CONSTLAT); +#endif +} + +void mpsl_lowpower_request_callbacqk(void) +{ +#if defined(CONFIG_NRFX_POWER) + nrfx_power_constlat_mode_free(); +#else + nrf_power_task_trigger(NRF_POWER, NRF_POWER_TASK_LOWPWR); +#endif +} +#endif /* defined(CONFIG_SOC_COMPATIBLE_NRF54LX) */ + SYS_INIT(mpsl_lib_init_sys, PRE_KERNEL_1, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT); SYS_INIT(mpsl_low_prio_init, POST_KERNEL, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT);