diff --git a/modules/hal_nordic/nrfx/Kconfig b/modules/hal_nordic/nrfx/Kconfig index 65894d48712..83ce3f157cc 100644 --- a/modules/hal_nordic/nrfx/Kconfig +++ b/modules/hal_nordic/nrfx/Kconfig @@ -169,6 +169,16 @@ config NRFX_PDM0 depends on $(dt_nodelabel_has_compat,pdm0,$(DT_COMPAT_NORDIC_NRF_PDM)) select NRFX_PDM +config NRFX_PDM20 + bool "PDM20 driver instance" + depends on $(dt_nodelabel_has_compat,pdm20,$(DT_COMPAT_NORDIC_NRF_PDM)) + select NRFX_PDM + +config NRFX_PDM21 + bool "PDM21 driver instance" + depends on $(dt_nodelabel_has_compat,pdm21,$(DT_COMPAT_NORDIC_NRF_PDM)) + select NRFX_PDM + config NRFX_POWER bool "POWER driver" depends on $(dt_has_compat,$(DT_COMPAT_NORDIC_NRF_POWER)) diff --git a/modules/hal_nordic/nrfx/nrfx_config.h b/modules/hal_nordic/nrfx/nrfx_config.h index 56e59879563..9b664c24374 100644 --- a/modules/hal_nordic/nrfx/nrfx_config.h +++ b/modules/hal_nordic/nrfx/nrfx_config.h @@ -209,11 +209,17 @@ #ifdef CONFIG_NRFX_PDM #define NRFX_PDM_ENABLED 1 #endif +#ifdef CONFIG_NRFX_PDM_LOG +#define NRFX_PDM_CONFIG_LOG_ENABLED 1 +#endif #ifdef CONFIG_NRFX_PDM0 #define NRFX_PDM0_ENABLED 1 #endif -#ifdef CONFIG_NRFX_PDM_LOG -#define NRFX_PDM_CONFIG_LOG_ENABLED 1 +#ifdef CONFIG_NRFX_PDM20 +#define NRFX_PDM20_ENABLED 1 +#endif +#ifdef CONFIG_NRFX_PDM21 +#define NRFX_PDM21_ENABLED 1 #endif #ifdef CONFIG_NRFX_POWER diff --git a/modules/hal_nordic/nrfx/nrfx_config_nrf5340_application.h b/modules/hal_nordic/nrfx/nrfx_config_nrf5340_application.h index a5dbcaa3db8..ab04db03f15 100644 --- a/modules/hal_nordic/nrfx/nrfx_config_nrf5340_application.h +++ b/modules/hal_nordic/nrfx/nrfx_config_nrf5340_application.h @@ -596,6 +596,15 @@ #define NRFX_PDM_CONFIG_LOG_LEVEL 3 #endif +/** + * @brief NRFX_PDM0_ENABLED + * + * Boolean. Accepted values 0 and 1. + */ +#ifndef NRFX_PDM0_ENABLED +#define NRFX_PDM0_ENABLED 0 +#endif + /** * @brief NRFX_POWER_ENABLED * diff --git a/soc/nordic/common/Kconfig.peripherals b/soc/nordic/common/Kconfig.peripherals index 57c90b05ef7..8ba97b225b9 100644 --- a/soc/nordic/common/Kconfig.peripherals +++ b/soc/nordic/common/Kconfig.peripherals @@ -129,6 +129,12 @@ config HAS_HW_NRF_OSCILLATORS config HAS_HW_NRF_PDM0 def_bool $(dt_nodelabel_enabled_with_compat,pdm0,$(DT_COMPAT_NORDIC_NRF_PDM)) +config HAS_HW_NRF_PDM20 + def_bool $(dt_nodelabel_enabled_with_compat,pdm20,$(DT_COMPAT_NORDIC_NRF_PDM)) + +config HAS_HW_NRF_PDM21 + def_bool $(dt_nodelabel_enabled_with_compat,pdm21,$(DT_COMPAT_NORDIC_NRF_PDM)) + config HAS_HW_NRF_POWER def_bool $(dt_compat_enabled,$(DT_COMPAT_NORDIC_NRF_POWER)) diff --git a/soc/nordic/validate_base_addresses.c b/soc/nordic/validate_base_addresses.c index 84d773159bc..07ae94a233b 100644 --- a/soc/nordic/validate_base_addresses.c +++ b/soc/nordic/validate_base_addresses.c @@ -222,6 +222,8 @@ CHECK_DT_REG(nfct, NRF_NFCT); CHECK_DT_REG(nrf_mpu, NRF_MPU); CHECK_DT_REG(oscillators, NRF_OSCILLATORS); CHECK_DT_REG(pdm0, NRF_PDM0); +CHECK_DT_REG(pdm20, NRF_PDM20); +CHECK_DT_REG(pdm21, NRF_PDM21); CHECK_DT_REG(power, NRF_POWER); CHECK_DT_REG(ppi, NRF_PPI); CHECK_DT_REG(pwm0, NRF_PWM0);