soc: nrf: Use data from DTS to populate HAS_HW_NRF_* Kconfig options

Instead of selecting appropriate HAS_HW_NRF_* options for particular
nRF SoCs (and simulated nRF52 target), set their values basing on
information from devicetree.
Correct also semantics of those options so that they are set only when
a corresponding DT node is enabled. This allows using them directly in
Kconfig dependencies of Zephyr drivers for nRF peripherals. Update
appropriately these dependencies.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
This commit is contained in:
Andrzej Głąbek 2022-03-28 13:38:03 +02:00 committed by Carles Cufí
commit 586e26e8fc
18 changed files with 178 additions and 837 deletions

View file

@ -7,19 +7,7 @@ config WDT_NRFX
bool "nRF WDT nrfx driver"
default y
depends on SOC_FAMILY_NRF
select NRFX_WDT
select NRFX_WDT0 if HAS_HW_NRF_WDT0
select NRFX_WDT1 if HAS_HW_NRF_WDT1
help
Enable support for nrfx WDT driver for nRF MCU series.
config NRFX_WDT0
bool "WDT0 instance"
depends on HAS_HW_NRF_WDT || HAS_HW_NRF_WDT0
default y
help
Enable support for nrfx WDT instance 0.
config NRFX_WDT1
bool "WDT1 instance"
depends on HAS_HW_NRF_WDT1
help
Enable support for nrfx WDT instance 1.