Skip to content

Commit fccbda1

Browse files
committed
tests: benchmarks: multicore: Run tests on IDLE with cache retained
Extend tests with configuration that checks driver operation together with Low Power CPU state IDLE with cache retained. Signed-off-by: Sebastian Głąb <[email protected]>
1 parent 52f3309 commit fccbda1

File tree

8 files changed

+200
-0
lines changed

8 files changed

+200
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
/*
2+
* Copyright (c) 2025 Nordic Semiconductor ASA
3+
*
4+
* SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5+
*/
6+
7+
/* Modify S2RAM low power state - increase it's min-residency
8+
* so the cpu stays at IDLE state.
9+
*/
10+
11+
/ {
12+
cpus {
13+
power-states {
14+
idle_cache_disabled: idle_cache_disabled {
15+
min-residency-us = <790000>;
16+
};
17+
18+
s2ram: s2ram {
19+
min-residency-us = <800000>;
20+
};
21+
};
22+
};
23+
};

tests/benchmarks/multicore/idle/testcase.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,19 @@ tests:
5252
- idle_SNIPPET=nordic-ppr-xip
5353
- CONFIG_FIRST_SLEEP_OFFSET=y
5454

55+
benchmarks.multicore.idle.nrf54h20dk_cpuapp_cpurad_retained:
56+
harness: console
57+
platform_allow:
58+
- nrf54h20dk/nrf54h20/cpuapp
59+
integration_platforms:
60+
- nrf54h20dk/nrf54h20/cpuapp
61+
extra_args:
62+
- CONFIG_SOC_NRF54H20_CPURAD_ENABLE=y
63+
- SB_CONF_FILE=sysbuild/nrf54h20dk_nrf54h20_cpurad.conf
64+
- CONFIG_FIRST_SLEEP_OFFSET=y
65+
- idle_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
66+
- remote_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
67+
5568
benchmarks.multicore.idle.nrf54h20dk_cpuapp_cpurad:
5669
harness: console
5770
platform_allow:

tests/benchmarks/multicore/idle_flpr/testcase.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,21 @@ tests:
2222
- "idle_flpr: Run 0"
2323
- "idle_flpr: Run 1"
2424

25+
26+
benchmarks.multicore.idle_flpr.idle_retained:
27+
tags: ppk_power_measure
28+
extra_args:
29+
- idle_flpr_CONF_FILE=prj_s2ram.conf
30+
- remote_flpr_CONF_FILE=prj_s2ram.conf
31+
- idle_flpr_CONFIG_TEST_SLEEP_DURATION_MS=500
32+
- remote_flpr_CONFIG_TEST_SLEEP_DURATION_MS=500
33+
- idle_flpr_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
34+
harness: pytest
35+
harness_config:
36+
fixture: ppk_power_measure
37+
pytest_root:
38+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_ppr_and_idle"
39+
2540
benchmarks.multicore.idle_flpr.idle:
2641
tags: ppk_power_measure
2742
extra_args:

tests/benchmarks/multicore/idle_ppr/testcase.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,23 @@ tests:
1919
- "idle_ppr: Run 0"
2020
- "idle_ppr: Run 1"
2121

22+
benchmarks.multicore.idle_ppr.idle_retained:
23+
tags: ppk_power_measure
24+
extra_args:
25+
- CONFIG_SOC_NRF54H20_CPURAD_ENABLE=y
26+
- idle_ppr_CONF_FILE=prj_s2ram.conf
27+
- remote_rad_CONF_FILE=prj_s2ram.conf
28+
- remote_ppr_CONF_FILE=prj_s2ram.conf
29+
- idle_ppr_CONFIG_TEST_SLEEP_DURATION_MS=500
30+
- remote_rad_CONFIG_TEST_SLEEP_DURATION_MS=500
31+
- remote_ppr_CONFIG_TEST_SLEEP_DURATION_MS=500
32+
- idle_ppr_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
33+
harness: pytest
34+
harness_config:
35+
fixture: ppk_power_measure
36+
pytest_root:
37+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_ppr_and_idle"
38+
2239
benchmarks.multicore.idle_ppr.idle:
2340
tags: ppk_power_measure
2441
extra_args:

tests/benchmarks/multicore/idle_pwm_led/testcase.yaml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,21 @@ tests:
2222
- "Multicore idle_pwm_led test iteration 0"
2323
- "Multicore idle_pwm_led test iteration 1"
2424

25+
benchmarks.multicore.idle_pwm_led.nrf54h20dk_cpuapp_cpurad.idle_retained:
26+
filter: not CONFIG_COVERAGE
27+
tags: ppk_power_measure
28+
extra_args:
29+
- idle_pwm_led_CONF_FILE=prj_s2ram.conf
30+
- remote_CONF_FILE=prj_s2ram.conf
31+
- idle_pwm_led_CONFIG_TEST_SLEEP_DURATION_MS=500
32+
- remote_CONFIG_TEST_SLEEP_DURATION_MS=500
33+
- idle_pwm_led_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
34+
harness: pytest
35+
harness_config:
36+
fixture: ppk_power_measure
37+
pytest_root:
38+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_idle"
39+
2540
benchmarks.multicore.idle_pwm_led.nrf54h20dk_cpuapp_cpurad.idle:
2641
filter: not CONFIG_COVERAGE
2742
tags: ppk_power_measure
@@ -49,6 +64,22 @@ tests:
4964
pytest_root:
5065
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_s2ram"
5166

67+
benchmarks.multicore.idle_pwm_led.nrf54h20dk_cpuapp_cpurad.idle_retained_fast:
68+
filter: not CONFIG_COVERAGE
69+
tags: ppk_power_measure
70+
extra_args:
71+
- idle_pwm_led_CONF_FILE=prj_s2ram.conf
72+
- remote_CONF_FILE=prj_s2ram.conf
73+
- idle_pwm_led_CONFIG_TEST_SLEEP_DURATION_MS=500
74+
- remote_CONFIG_TEST_SLEEP_DURATION_MS=500
75+
- idle_pwm_led_DTC_OVERLAY_FILE="boards/nrf54h20dk_nrf54h20_cpuapp_fast_p7_0.overlay"
76+
- idle_pwm_led_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
77+
harness: pytest
78+
harness_config:
79+
fixture: ppk_power_measure
80+
pytest_root:
81+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_idle"
82+
5283
benchmarks.multicore.idle_pwm_led.nrf54h20dk_cpuapp_cpurad.idle_fast:
5384
filter: not CONFIG_COVERAGE
5485
tags: ppk_power_measure

tests/benchmarks/multicore/idle_pwm_loopback/testcase.yaml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,21 @@ tests:
2323
- "Iteration 0"
2424
- "Iteration 1"
2525

26+
benchmarks.multicore.idle_pwm_loopback.nrf54h20dk_cpuapp_cpurad.idle_retained:
27+
filter: not CONFIG_COVERAGE
28+
tags: ppk_power_measure
29+
extra_args:
30+
- idle_pwm_loopback_CONF_FILE=prj_s2ram.conf
31+
- remote_CONF_FILE=prj_s2ram.conf
32+
- idle_pwm_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
33+
- remote_CONFIG_TEST_SLEEP_DURATION_MS=500
34+
- idle_pwm_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
35+
harness: pytest
36+
harness_config:
37+
fixture: spi_loopback
38+
pytest_root:
39+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_idle"
40+
2641
benchmarks.multicore.idle_pwm_loopback.nrf54h20dk_cpuapp_cpurad.idle:
2742
filter: not CONFIG_COVERAGE
2843
tags: ppk_power_measure
@@ -64,6 +79,22 @@ tests:
6479
- "Iteration 0"
6580
- "Iteration 1"
6681

82+
benchmarks.multicore.idle_pwm_loopback.nrf54h20dk_cpuapp_cpurad.idle_retained_fast:
83+
filter: not CONFIG_COVERAGE
84+
tags: ppk_power_measure
85+
extra_args:
86+
- idle_pwm_loopback_CONF_FILE=prj_s2ram.conf
87+
- remote_CONF_FILE=prj_s2ram.conf
88+
- idle_pwm_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
89+
- remote_CONFIG_TEST_SLEEP_DURATION_MS=500
90+
- idle_pwm_loopback_DTC_OVERLAY_FILE="boards/nrf54h20dk_nrf54h20_cpuapp_fast_p7_1.overlay"
91+
- idle_pwm_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
92+
harness: pytest
93+
harness_config:
94+
fixture: spi_loopback
95+
pytest_root:
96+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_idle"
97+
6798
benchmarks.multicore.idle_pwm_loopback.nrf54h20dk_cpuapp_cpurad.idle_fast:
6899
filter: not CONFIG_COVERAGE
69100
tags: ppk_power_measure

tests/benchmarks/multicore/idle_spim_loopback/testcase.yaml

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,19 @@ tests:
3030
- ".*Run 0 - PASS"
3131
- ".*Run 1 - PASS"
3232

33+
benchmarks.multicore.idle_spim_loopback.4_bytes.idle_retained:
34+
filter: not CONFIG_COVERAGE
35+
tags: ppk_power_measure
36+
extra_args:
37+
- idle_spim_loopback_CONF_FILE=prj_s2ram.conf
38+
- idle_spim_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
39+
- idle_spim_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
40+
harness: pytest
41+
harness_config:
42+
fixture: spi_loopback
43+
pytest_root:
44+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_spim_and_idle"
45+
3346
benchmarks.multicore.idle_spim_loopback.4_bytes.idle:
3447
filter: not CONFIG_COVERAGE
3548
tags: ppk_power_measure
@@ -68,6 +81,20 @@ tests:
6881
- ".*Run 0 - PASS"
6982
- ".*Run 1 - PASS"
7083

84+
benchmarks.multicore.idle_spim_loopback.4_bytes.idle_retained_fast:
85+
filter: not CONFIG_COVERAGE
86+
tags: ppk_power_measure
87+
extra_args:
88+
- idle_spim_loopback_CONF_FILE=prj_s2ram.conf
89+
- idle_spim_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
90+
- idle_spim_loopback_DTC_OVERLAY_FILE="boards/nrf54h20dk_nrf54h20_cpuapp_fast.overlay"
91+
- idle_spim_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
92+
harness: pytest
93+
harness_config:
94+
fixture: spi_loopback
95+
pytest_root:
96+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_spim_and_idle"
97+
7198
benchmarks.multicore.idle_spim_loopback.4_bytes.idle_fast:
7299
filter: not CONFIG_COVERAGE
73100
tags: ppk_power_measure
@@ -197,6 +224,20 @@ tests:
197224
- ".*Run 0 - PASS"
198225
- ".*Run 1 - PASS"
199226

227+
benchmarks.multicore.idle_spim_loopback.16_bytes.idle_retained:
228+
filter: not CONFIG_COVERAGE
229+
tags: ppk_power_measure
230+
extra_args:
231+
- idle_spim_loopback_CONF_FILE=prj_s2ram.conf
232+
- idle_spim_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
233+
- idle_spim_loopback_CONFIG_DATA_FIELD=16
234+
- idle_spim_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
235+
harness: pytest
236+
harness_config:
237+
fixture: spi_loopback
238+
pytest_root:
239+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_spim_and_idle"
240+
200241
benchmarks.multicore.idle_spim_loopback.16_bytes.idle:
201242
filter: not CONFIG_COVERAGE
202243
tags: ppk_power_measure
@@ -239,6 +280,21 @@ tests:
239280
- ".*Run 0 - PASS"
240281
- ".*Run 1 - PASS"
241282

283+
benchmarks.multicore.idle_spim_loopback.16_bytes.idle_retained_fast:
284+
filter: not CONFIG_COVERAGE
285+
tags: ppk_power_measure
286+
extra_args:
287+
- idle_spim_loopback_CONF_FILE=prj_s2ram.conf
288+
- idle_spim_loopback_CONFIG_TEST_SLEEP_DURATION_MS=500
289+
- idle_spim_loopback_DTC_OVERLAY_FILE="boards/nrf54h20dk_nrf54h20_cpuapp_fast.overlay"
290+
- idle_spim_loopback_CONFIG_DATA_FIELD=16
291+
- idle_spim_loopback_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
292+
harness: pytest
293+
harness_config:
294+
fixture: spi_loopback
295+
pytest_root:
296+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_spim_and_idle"
297+
242298
benchmarks.multicore.idle_spim_loopback.16_bytes.idle_fast:
243299
filter: not CONFIG_COVERAGE
244300
tags: ppk_power_measure

tests/benchmarks/multicore/idle_wdt/testcase.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,20 @@ tests:
2121
- "Run 0"
2222
- "Run 1"
2323

24+
benchmarks.multicore.idle_wdt.nrf54h20dk_cpuapp_cpurad.idle_retained:
25+
tags: ppk_power_measure
26+
extra_args:
27+
- idle_wdt_CONF_FILE=prj_s2ram.conf
28+
- remote_CONF_FILE=prj_s2ram.conf
29+
- idle_wdt_CONFIG_TEST_SLEEP_DURATION_MS=500
30+
- remote_CONFIG_TEST_SLEEP_DURATION_MS=500
31+
- idle_wdt_EXTRA_DTC_OVERLAY_FILE="${ZEPHYR_NRF_MODULE_DIR}/tests/benchmarks/multicore/common/workaround_idle_retained.overlay"
32+
harness: pytest
33+
harness_config:
34+
fixture: ppk_power_measure
35+
pytest_root:
36+
- "${CUSTOM_ROOT_TEST_DIR}/test_measure_power_consumption.py::test_measure_and_data_dump_pwm_and_idle"
37+
2438
benchmarks.multicore.idle_wdt.nrf54h20dk_cpuapp_cpurad.idle:
2539
tags: ppk_power_measure
2640
extra_args:

0 commit comments

Comments
 (0)