1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
RIOT/cpu/stm32/kconfigs/f0f1f3/Kconfig.clk
MrKevinWeiss 28aed3cb97
cpu/stm32/kconfig: rework clock tree
This splits up the clock configs.
It allows CPU_FAM based file sourcing and also common CPU_FAMs.
The dependancies are also included in wildcards would be used for the CPU_FAM macro.
This should be much more readable.
This also takes into account the HSE speeds in order to match the make/header resolution.
Some hidden symbols were added to make sorting many CPU_SERIES dependencies easier.
2022-11-03 11:37:33 +01:00

32 lines
973 B
Plaintext

# Copyright (c) 2022 HAW Hamburg
#
# This file is subject to the terms and conditions of the GNU Lesser
# General Public License v2.1. See the file LICENSE in the top level
# directory for more details.
#
if CPU_FAM_F0 || CPU_FAM_F1 || CPU_FAM_F3
config CLOCK_PLL_PREDIV
int "PLLIN division factor" if CUSTOM_PLL_PARAMS && !HAVE_CLOCK_PLL_PREDIV_HARDWIRED_2
default 2 if HAVE_CLOCK_PLL_PREDIV_HARDWIRED_2 || CLOCK_HSE = 16000000
default 1
range 1 16
config CLOCK_PLL_MUL
int "PLLIN multiply factor" if CUSTOM_PLL_PARAMS
default 12 if CPU_FAM_F0 && HAVE_CLOCK_PLL_PREDIV_HARDWIRED_2
default 6 if CPU_FAM_F0
default 16 if CPU_FAM_F3 && HAVE_CLOCK_PLL_PREDIV_HARDWIRED_2
default 9 if CPU_FAM_F1 || CPU_FAM_F3
range 2 16
config HAVE_CLOCK_PLL_PREDIV_HARDWIRED_2
bool
help
Indicated that this CPU Line has the prediv hardwired to 2, making it
unable to change.
endif # CPU_FAM_F0 || CPU_FAM_F1 || CPU_FAM_F3