From e938ba218ffe5bf48c79c61d4a9e9404483aee33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C5=82=C4=85b?= Date: Thu, 12 Dec 2024 14:38:46 +0100 Subject: [PATCH] [nrf fromtree] tests: drivers: watchdog: Run tests on nRF54L20pdk MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add overlays and align watchdog tests to be executed on nrf54L20pdk. Signed-off-by: Sebastian Głąb (cherry picked from commit df20c6d70fbddce7491329c773d6423dc2912b9b) --- .../nordic/nrf54l20pdk/nrf54l20pdk_nrf54l20_cpuapp.yaml | 1 + .../watchdog/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay | 8 ++++++++ .../boards/nrf54l20pdk_nrf54l20_cpuapp.overlay | 9 +++++++++ .../boards/nrf54l20pdk_nrf54l20_cpuapp.overlay | 9 +++++++++ tests/drivers/watchdog/wdt_error_cases/src/main.c | 4 ++-- tests/drivers/watchdog/wdt_error_cases/testcase.yaml | 1 + 6 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 samples/drivers/watchdog/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay create mode 100644 tests/drivers/watchdog/wdt_basic_api/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay create mode 100644 tests/drivers/watchdog/wdt_error_cases/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay diff --git a/boards/nordic/nrf54l20pdk/nrf54l20pdk_nrf54l20_cpuapp.yaml b/boards/nordic/nrf54l20pdk/nrf54l20pdk_nrf54l20_cpuapp.yaml index d11ea0d869f..99b87bea0c2 100644 --- a/boards/nordic/nrf54l20pdk/nrf54l20pdk_nrf54l20_cpuapp.yaml +++ b/boards/nordic/nrf54l20pdk/nrf54l20pdk_nrf54l20_cpuapp.yaml @@ -15,3 +15,4 @@ flash: 449 supported: - counter - gpio + - watchdog diff --git a/samples/drivers/watchdog/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay b/samples/drivers/watchdog/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay new file mode 100644 index 00000000000..5c765a8a896 --- /dev/null +++ b/samples/drivers/watchdog/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay @@ -0,0 +1,8 @@ +/* + * Copyright 2024 Nordic Semiconductor ASA + * SPDX-License-Identifier: Apache-2.0 + */ + +&wdt31 { + status = "okay"; +}; diff --git a/tests/drivers/watchdog/wdt_basic_api/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay b/tests/drivers/watchdog/wdt_basic_api/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay new file mode 100644 index 00000000000..8d3dce3b380 --- /dev/null +++ b/tests/drivers/watchdog/wdt_basic_api/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay @@ -0,0 +1,9 @@ +/* + * Copyright (c) 2024 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: Apache-2.0 + */ + +&wdt31 { + status = "okay"; +}; diff --git a/tests/drivers/watchdog/wdt_error_cases/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay b/tests/drivers/watchdog/wdt_error_cases/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay new file mode 100644 index 00000000000..8d3dce3b380 --- /dev/null +++ b/tests/drivers/watchdog/wdt_error_cases/boards/nrf54l20pdk_nrf54l20_cpuapp.overlay @@ -0,0 +1,9 @@ +/* + * Copyright (c) 2024 Nordic Semiconductor ASA + * + * SPDX-License-Identifier: Apache-2.0 + */ + +&wdt31 { + status = "okay"; +}; diff --git a/tests/drivers/watchdog/wdt_error_cases/src/main.c b/tests/drivers/watchdog/wdt_error_cases/src/main.c index 3182cdebd03..990b2b52c98 100644 --- a/tests/drivers/watchdog/wdt_error_cases/src/main.c +++ b/tests/drivers/watchdog/wdt_error_cases/src/main.c @@ -42,8 +42,8 @@ #define DEFAULT_WINDOW_MIN (0U) /* Align tests to the specific target: */ -#if defined(CONFIG_SOC_NRF54L05) || defined(CONFIG_SOC_NRF54L10) || \ - defined(CONFIG_SOC_NRF54L15) || defined(CONFIG_SOC_NRF54H20) || defined(CONFIG_SOC_NRF9280) +#if defined(CONFIG_SOC_SERIES_NRF54LX) || defined(CONFIG_SOC_NRF54H20) || \ + defined(CONFIG_SOC_NRF9280) #define WDT_TEST_FLAGS \ (WDT_DISABLE_SUPPORTED | WDT_FLAG_RESET_SOC_SUPPORTED | \ WDT_FLAG_ONLY_ONE_TIMEOUT_VALUE_SUPPORTED | WDT_OPT_PAUSE_IN_SLEEP_SUPPORTED | \ diff --git a/tests/drivers/watchdog/wdt_error_cases/testcase.yaml b/tests/drivers/watchdog/wdt_error_cases/testcase.yaml index 3a3dbf94358..e417cc16e45 100644 --- a/tests/drivers/watchdog/wdt_error_cases/testcase.yaml +++ b/tests/drivers/watchdog/wdt_error_cases/testcase.yaml @@ -9,6 +9,7 @@ tests: drivers.watchdog.wdt_error_cases: platform_allow: - nrf54l15dk/nrf54l15/cpuapp + - nrf54l20pdk/nrf54l20/cpuapp - nrf54h20dk/nrf54h20/cpuapp - nrf54h20dk/nrf54h20/cpurad - nrf9280pdk/nrf9280/cpuapp