From: Tom Rini Date: Wed, 30 Mar 2022 22:07:22 +0000 (-0400) Subject: Convert CONFIG_SH_SCIF_CLK_FREQ to Kconfig X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=5d14c336b21da34d07e93b5689ccffd52b8cc658;p=u-boot.git Convert CONFIG_SH_SCIF_CLK_FREQ to Kconfig This converts the following to Kconfig: CONFIG_SH_SCIF_CLK_FREQ Signed-off-by: Tom Rini --- diff --git a/configs/stout_defconfig b/configs/stout_defconfig index 0502ae5d30..ea07ceb8f3 100644 --- a/configs/stout_defconfig +++ b/configs/stout_defconfig @@ -88,6 +88,7 @@ CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y CONFIG_SCIF_CONSOLE=y +CONFIG_SH_SCIF_CLK_FREQ=52000000 CONFIG_SPI=y CONFIG_DM_SPI=y CONFIG_SH_QSPI=y diff --git a/drivers/serial/Kconfig b/drivers/serial/Kconfig index af01e506d5..286c99800f 100644 --- a/drivers/serial/Kconfig +++ b/drivers/serial/Kconfig @@ -825,6 +825,11 @@ config CONS_SCIFA0 endchoice +config SH_SCIF_CLK_FREQ + int "SCIF console clock frequency" + depends on SCIF_CONSOLE && (!DM_SERIAL || (SPL && !SPL_DM_SERIAL)) + default 65000000 + config SEMIHOSTING_SERIAL bool "Semihosting UART support" depends on SEMIHOSTING && !SERIAL_RX_BUFFER diff --git a/include/configs/alt.h b/include/configs/alt.h index 1656072ebb..090bee7d2d 100644 --- a/include/configs/alt.h +++ b/include/configs/alt.h @@ -41,8 +41,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __ALT_H */ diff --git a/include/configs/armadillo-800eva.h b/include/configs/armadillo-800eva.h index f144302a71..acd140ee35 100644 --- a/include/configs/armadillo-800eva.h +++ b/include/configs/armadillo-800eva.h @@ -67,7 +67,4 @@ #define CONFIG_SH_ETHER_SH7734_MII (0x01) #define CONFIG_SH_ETHER_PHY_MODE PHY_INTERFACE_MODE_MII -/* Board Clock */ -#define CONFIG_SH_SCIF_CLK_FREQ get_board_sys_clk() - #endif /* __ARMADILLO_800EVA_H */ diff --git a/include/configs/gose.h b/include/configs/gose.h index 9015cabc2d..4ffa5bea8f 100644 --- a/include/configs/gose.h +++ b/include/configs/gose.h @@ -36,8 +36,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __GOSE_H */ diff --git a/include/configs/koelsch.h b/include/configs/koelsch.h index 3fef4150b2..c0997aa3dd 100644 --- a/include/configs/koelsch.h +++ b/include/configs/koelsch.h @@ -36,8 +36,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __KOELSCH_H */ diff --git a/include/configs/kzm9g.h b/include/configs/kzm9g.h index f35549d95a..7e99490e52 100644 --- a/include/configs/kzm9g.h +++ b/include/configs/kzm9g.h @@ -66,7 +66,6 @@ /* Clock */ #define CONFIG_GLOBAL_TIMER #define CONFIG_SYS_CPU_CLK (1196000000) -#define CONFIG_SH_SCIF_CLK_FREQ get_board_sys_clk() #define TMU_CLK_DIVIDER (4) /* 4 (default), 16, 64, 256 or 1024 */ #endif /* __KZM9G_H */ diff --git a/include/configs/lager.h b/include/configs/lager.h index df3b4bbce0..a5abbaaeab 100644 --- a/include/configs/lager.h +++ b/include/configs/lager.h @@ -37,8 +37,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __LAGER_H */ diff --git a/include/configs/porter.h b/include/configs/porter.h index 964ce7def6..bf380ddf05 100644 --- a/include/configs/porter.h +++ b/include/configs/porter.h @@ -41,8 +41,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __PORTER_H */ diff --git a/include/configs/rcar-gen3-common.h b/include/configs/rcar-gen3-common.h index 5bb6bf3d78..64743382ed 100644 --- a/include/configs/rcar-gen3-common.h +++ b/include/configs/rcar-gen3-common.h @@ -59,8 +59,5 @@ #endif #define CONFIG_SPL_STACK 0xe6304000 #define CONFIG_SPL_MAX_SIZE 0x7000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __RCAR_GEN3_COMMON_H */ diff --git a/include/configs/silk.h b/include/configs/silk.h index ec8740b382..574ba228d8 100644 --- a/include/configs/silk.h +++ b/include/configs/silk.h @@ -41,8 +41,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 65000000 -#endif #endif /* __SILK_H */ diff --git a/include/configs/stout.h b/include/configs/stout.h index 4ddbea5b1d..bcc6fcd36b 100644 --- a/include/configs/stout.h +++ b/include/configs/stout.h @@ -45,8 +45,5 @@ /* SPL support */ #define CONFIG_SPL_STACK 0xe6340000 #define CONFIG_SPL_MAX_SIZE 0x4000 -#ifdef CONFIG_SPL_BUILD -#define CONFIG_SH_SCIF_CLK_FREQ 52000000 -#endif #endif /* __STOUT_H */