cpu/stm32/clk: cleanup common clock configuration
This commit is contained in:
parent
dfed1b0567
commit
5fef40ab5a
@ -40,14 +40,6 @@ extern "C" {
|
||||
#endif
|
||||
#endif /* CONFIG_USE_CLOCK_PLL */
|
||||
|
||||
#ifndef CONFIG_USE_CLOCK_HSE
|
||||
#define CONFIG_USE_CLOCK_HSE 0
|
||||
#endif /* CONFIG_USE_CLOCK_HSE */
|
||||
|
||||
#ifndef CONFIG_USE_CLOCK_HSI
|
||||
#define CONFIG_USE_CLOCK_HSI 0
|
||||
#endif /* CONFIG_USE_CLOCK_HSI */
|
||||
|
||||
#if IS_ACTIVE(CONFIG_USE_CLOCK_PLL) && \
|
||||
(IS_ACTIVE(CONFIG_USE_CLOCK_HSE) || IS_ACTIVE(CONFIG_USE_CLOCK_HSI))
|
||||
#error "Cannot use PLL as clock source with other clock configurations"
|
||||
@ -63,10 +55,6 @@ extern "C" {
|
||||
#error "Cannot use HSI as clock source with other clock configurations"
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_BOARD_HAS_HSE
|
||||
#define CONFIG_BOARD_HAS_HSE 0
|
||||
#endif
|
||||
|
||||
#ifndef CLOCK_HSE
|
||||
#if defined(CPU_FAM_STM32G0) || defined(CPU_FAM_STM32G4) || \
|
||||
defined(CPU_FAM_STM32MP1)
|
||||
@ -76,10 +64,6 @@ extern "C" {
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_BOARD_HAS_LSE
|
||||
#define CONFIG_BOARD_HAS_LSE 0
|
||||
#endif
|
||||
|
||||
#if defined(CPU_FAM_STM32F0) || defined(CPU_FAM_STM32F1) || \
|
||||
defined(CPU_FAM_STM32F3)
|
||||
#define CLOCK_HSI MHZ(8)
|
||||
|
||||
@ -41,18 +41,6 @@ extern "C" {
|
||||
#endif
|
||||
#endif /* CONFIG_USE_CLOCK_PLL */
|
||||
|
||||
#ifndef CONFIG_USE_CLOCK_MSI
|
||||
#define CONFIG_USE_CLOCK_MSI 0
|
||||
#endif /* CONFIG_USE_CLOCK_MSI */
|
||||
|
||||
#ifndef CONFIG_USE_CLOCK_HSE
|
||||
#define CONFIG_USE_CLOCK_HSE 0
|
||||
#endif /* CONFIG_USE_CLOCK_HSE */
|
||||
|
||||
#ifndef CONFIG_USE_CLOCK_HSI
|
||||
#define CONFIG_USE_CLOCK_HSI 0
|
||||
#endif /* CONFIG_USE_CLOCK_HSI */
|
||||
|
||||
#if IS_ACTIVE(CONFIG_USE_CLOCK_PLL) && \
|
||||
(IS_ACTIVE(CONFIG_USE_CLOCK_MSI) || IS_ACTIVE(CONFIG_USE_CLOCK_HSE) || \
|
||||
IS_ACTIVE(CONFIG_USE_CLOCK_HSI))
|
||||
@ -77,10 +65,6 @@ extern "C" {
|
||||
#error "Cannot use HSI as clock source with other clock configurations"
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_BOARD_HAS_HSE
|
||||
#define CONFIG_BOARD_HAS_HSE 0
|
||||
#endif
|
||||
|
||||
#ifndef CLOCK_HSE
|
||||
#if defined(CPU_FAM_STM32L0) || defined(CPU_FAM_STM32L1)
|
||||
#define CLOCK_HSE MHZ(24)
|
||||
@ -89,10 +73,6 @@ extern "C" {
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_BOARD_HAS_LSE
|
||||
#define CONFIG_BOARD_HAS_LSE 0
|
||||
#endif
|
||||
|
||||
#define CLOCK_HSI MHZ(16)
|
||||
|
||||
#ifndef CONFIG_CLOCK_MSI
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user