Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cpu/stm32: Restructure stm32 clk kconfig model #18771

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .murdock
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ export DLCACHE_DIR=${DLCACHE_DIR:-~/.dlcache}
export ENABLE_TEST_CACHE=${ENABLE_TEST_CACHE:-1}
export MURDOCK_REDIS_HOST=${MURDOCK_REDIS_HOST:-127.0.0.1}

NIGHTLY=${NIGHTLY:-0}
NIGHTLY=${NIGHTLY:-1}
FULL_BUILD=${FULL_BUILD:-${NIGHTLY}}

# This is a work around for a bug in CCACHE which interacts very badly with
Expand Down
34 changes: 23 additions & 11 deletions cpu/stm32/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ config CPU_STM32
# This CPU requires periph_rtc when periph_rtc_mem
select MODULE_PERIPH_RTC if MODULE_PERIPH_RTC_MEM && HAS_PERIPH_RTC

menu "STM32 configuration"

# Common CPU symbol
config CPU
default "stm32" if CPU_STM32
Expand All @@ -39,22 +41,30 @@ config MODULE_BOOTLOADER_STM32
depends on HAS_BOOTLOADER_STM32
depends on TEST_KCONFIG

orsource "kconfigs/Kconfig.clk"
orsource "kconfigs/*/Kconfig"
orsource "kconfigs/*/Kconfig.lines"
orsource "kconfigs/*/Kconfig.models"

menu "STM32 clock configuration"
depends on CPU_STM32

rsource "kconfigs/Kconfig.clk"
rsource "kconfigs/$(CPU_FAM)/Kconfig.clk"

endmenu

rsource "kconfigs/$(CPU_FAM)/Kconfig"
rsource "kconfigs/$(CPU_FAM)/Kconfig.lines"
rsource "kconfigs/$(CPU_FAM)/Kconfig.models"

choice
prompt "ReaDout Protection level"
default RDP0
help
Set minimum running RDP level.
RDP0 is full debug permissions, RDP1 disables read from Flash but
otherwise leaves debug enabled, RDP2 disables JTAG completely. If
there is a mismatch between desired RDP level here and RDP level
set on the chip, early cpu init will hang. This ensures production
devices with the wrong RDP level, by fault or malace intent, will
not run. See cpu manual for further details on RDP.
Set minimum running RDP level.
RDP0 is full debug permissions, RDP1 disables read from Flash but
otherwise leaves debug enabled, RDP2 disables JTAG completely. If
there is a mismatch between desired RDP level here and RDP level
set on the chip, early cpu init will hang. This ensures production
devices with the wrong RDP level, by fault or malace intent, will
not run. See cpu manual for further details on RDP.
depends on (CPU_FAM_F1 || CPU_FAM_F2 || CPU_FAM_F3 || CPU_FAM_F4 || CPU_FAM_F7)
config RDP0
bool "RDP0"
Expand All @@ -72,4 +82,6 @@ rsource "vectors/Kconfig"

endif # TEST_KCONFIG

endmenu

source "$(RIOTCPU)/cortexm_common/Kconfig"
Loading