From 0cadaf116f883d4996e9690ae3cf6fb193c55d51 Mon Sep 17 00:00:00 2001 From: Jonathan Rico Date: Wed, 12 Jun 2024 11:10:08 +0200 Subject: [PATCH] [nrf fromlist] hal_nordic: Fix reserved PPI faulty logic The list of reserved PPIs by MPSL should be kept if MPSL is enabled. The 802154 radio driver is not the only user of MPSL. Upstream PR: https://github.com/zephyrproject-rtos/zephyr/pull/74139 Signed-off-by: Jonathan Rico --- modules/hal_nordic/nrfx/Kconfig | 4 ++++ modules/hal_nordic/nrfx/nrfx_glue.h | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/hal_nordic/nrfx/Kconfig b/modules/hal_nordic/nrfx/Kconfig index 10ecd585ef3..35c336f40ef 100644 --- a/modules/hal_nordic/nrfx/Kconfig +++ b/modules/hal_nordic/nrfx/Kconfig @@ -9,6 +9,10 @@ menu "nrfx drivers" rsource "Kconfig.logging" +config MPSL + bool + # Dummy kconfig to allow compiling outside of NCS + config NRFX_ADC bool "ADC driver" depends on $(dt_has_compat,$(DT_COMPAT_NORDIC_NRF_ADC)) diff --git a/modules/hal_nordic/nrfx/nrfx_glue.h b/modules/hal_nordic/nrfx/nrfx_glue.h index 0dd8b2bba94..2d4c25f4383 100644 --- a/modules/hal_nordic/nrfx/nrfx_glue.h +++ b/modules/hal_nordic/nrfx/nrfx_glue.h @@ -378,7 +378,7 @@ void nrfx_busy_wait(uint32_t usec_to_wait); #define NRFX_PPI_GROUPS_USED_BY_802154_DRV 0 #endif // CONFIG_NRF_802154_RADIO_DRIVER -#if defined(CONFIG_NRF_802154_RADIO_DRIVER) && !defined(CONFIG_NRF_802154_SL_OPENSOURCE) +#if defined(CONFIG_MPSL) #include #define NRFX_PPI_CHANNELS_USED_BY_MPSL MPSL_RESERVED_PPI_CHANNELS #define NRFX_PPI_GROUPS_USED_BY_MPSL 0