Skip to content

Commit ff3cf73

Browse files
committed
nrf92 sysoff/sysonallidle
1 parent e48bca4 commit ff3cf73

File tree

15 files changed

+1296
-30
lines changed

15 files changed

+1296
-30
lines changed

dts/common/nordic/nrf9280.dtsi

Lines changed: 276 additions & 24 deletions
Large diffs are not rendered by default.

soc/nordic/common/poweroff.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
#if defined(CONFIG_SOC_SERIES_NRF51X) || defined(CONFIG_SOC_SERIES_NRF52X)
1111
#include <hal/nrf_power.h>
12-
#elif defined(CONFIG_SOC_SERIES_NRF54HX)
12+
#elif defined(CONFIG_SOC_SERIES_NRF54HX) || defined(CONFIG_SOC_SERIES_NRF92X)
1313
#include <power.h>
1414
#else
1515
#include <hal/nrf_regulators.h>
@@ -63,7 +63,7 @@ void z_sys_poweroff(void)
6363
#endif
6464
#if defined(CONFIG_SOC_SERIES_NRF51X) || defined(CONFIG_SOC_SERIES_NRF52X)
6565
nrf_power_system_off(NRF_POWER);
66-
#elif defined(CONFIG_SOC_SERIES_NRF54HX)
66+
#elif defined(CONFIG_SOC_SERIES_NRF54HX) || defined(CONFIG_SOC_SERIES_NRF92X)
6767
nrf_poweroff();
6868
#else
6969
nrf_regulators_system_off(NRF_REGULATORS);

soc/nordic/nrf92/CMakeLists.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,18 @@
33

44
if(CONFIG_ARM)
55
zephyr_library_sources(soc.c)
6+
if(CONFIG_PM OR CONFIG_POWEROFF)
7+
zephyr_library_sources(power.c)
8+
endif()
69
endif()
710

11+
zephyr_library_sources_ifdef(CONFIG_PM_S2RAM pm_s2ram.c)
12+
813
zephyr_include_directories(.)
14+
zephyr_include_directories(..)
915

1016
# Ensure that image size aligns with 16 bytes so that MRAMC finalizes all writes
1117
# for the image correctly
1218
zephyr_linker_sources(SECTIONS SORT_KEY zzz_place_align_at_end align.ld)
19+
20+
add_subdirectory(gpd)

soc/nordic/nrf92/Kconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ config SOC_NRF9230_ENGB_CPUAPP
2727
select NRFS_HAS_PMIC_SERVICE
2828
select NRFS_HAS_TEMP_SERVICE
2929
select NRFS_HAS_VBUS_DETECTOR_SERVICE
30+
select HAS_PM
3031

3132
config SOC_NRF9230_ENGB_CPURAD
3233
select ARM
@@ -45,6 +46,9 @@ config SOC_NRF9230_ENGB_CPURAD
4546
select NRFS_HAS_MRAM_SERVICE
4647
select NRFS_HAS_PMIC_SERVICE
4748
select NRFS_HAS_TEMP_SERVICE
49+
select HAS_PM
4850

4951
config SOC_NRF9230_ENGB_CPUPPR
5052
select RISCV_CORE_NORDIC_VPR
53+
54+
rsource "gpd/Kconfig"

soc/nordic/nrf92/Kconfig.defconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ config BUILD_OUTPUT_HEX
2929

3030
config SYS_CLOCK_HW_CYCLES_PER_SEC
3131
default 1000000 if NRF_GRTC_TIMER
32+
default 32768 if NRF_RTC_TIMER
3233

3334
endif # RISCV
3435

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Copyright (c) 2024 Nordic Semiconductor
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
zephyr_library_sources_ifdef(CONFIG_SOC_NRF9220_GPD gpd.c)
5+
zephyr_include_directories(include)

soc/nordic/nrf92/gpd/Kconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Copyright (c) 2024 Nordic Semiconductor
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config SOC_NRF54H20_GPD
5+
bool "Global Power Domain service"
6+
imply NRFS
7+
imply NRFS_GDPWR_SERVICE_ENABLED
8+
select ONOFF
9+
default y if SOC_NRF54H20_CPUAPP || SOC_NRF54H20_CPURAD
10+
help
11+
This option enables the Global Power Domain service.

0 commit comments

Comments
 (0)