All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] armv8: fsl-lsch3: convert CONFIG_TARGET_x to CONFIG_ARCH_x
@ 2019-10-21 23:10 Michael Walle
  2019-11-11 15:18 ` Priyanka Jain
  0 siblings, 1 reply; 2+ messages in thread
From: Michael Walle @ 2019-10-21 23:10 UTC (permalink / raw)
  To: u-boot

The clocks are not dependent on the target but only on the SoC.
Therefore, convert the CONFIG_TARGET_x macros to the corresponding
CONFIG_ARCH_x. This will allow other targets to automatically use the
common code. Otherwise every new target would have to add itself to the
"#if defined(CONFIG_TARGET_x) || .." macros.

Signed-off-by: Michael Walle <michael@walle.cc>
---
 arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_speed.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_speed.c b/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_speed.c
index b3e67321b4..bbd550b036 100644
--- a/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_speed.c
+++ b/arch/arm/cpu/armv8/fsl-layerscape/fsl_lsch3_speed.c
@@ -64,7 +64,7 @@ void get_sys_info(struct sys_info *sys_info)
 	};
 
 	uint i, cluster;
-#if defined(CONFIG_TARGET_LS1028ARDB) || defined(CONFIG_TARGET_LS1088ARDB)
+#if defined(CONFIG_ARCH_LS1028A) || defined(CONFIG_ARCH_LS1088A)
 	uint rcw_tmp;
 #endif
 	uint freq_c_pll[CONFIG_SYS_FSL_NUM_CC_PLLS];
@@ -131,7 +131,7 @@ void get_sys_info(struct sys_info *sys_info)
 						CONFIG_SYS_FSL_IFC_CLK_DIV;
 #endif
 
-#if defined(CONFIG_TARGET_LS1028ARDB) || defined(CONFIG_TARGET_LS1088ARDB)
+#if defined(CONFIG_ARCH_LS1028A) || defined(CONFIG_ARCH_LS1088A)
 #define HWA_CGA_M2_CLK_SEL      0x00380000
 #define HWA_CGA_M2_CLK_SHIFT    19
 	rcw_tmp = in_le32(&gur->rcwsr[5]);
@@ -159,7 +159,7 @@ void get_sys_info(struct sys_info *sys_info)
 		break;
 	}
 #endif
-#if defined(CONFIG_TARGET_LX2160ARDB) || defined(CONFIG_TARGET_LS2080ARDB)
+#if defined(CONFIG_ARCH_LX2160A) || defined(CONFIG_ARCH_LS2080A)
 	sys_info->freq_cga_m2 = sys_info->freq_systembus;
 #endif
 }
@@ -176,10 +176,10 @@ int get_clocks(void)
 #endif
 #if defined(CONFIG_FSL_ESDHC)
 #if defined(CONFIG_FSL_ESDHC_USE_PERIPHERAL_CLK)
-#if defined(CONFIG_TARGET_LS1028ARDB) || defined(CONFIG_TARGET_LX2160ARDB)
+#if defined(CONFIG_ARCH_LS1028A) || defined(CONFIG_ARCH_LX2160A)
 	gd->arch.sdhc_clk = sys_info.freq_cga_m2 / 2;
 #endif
-#if defined(CONFIG_TARGET_LS2080ARDB) || defined(CONFIG_TARGET_LS1088ARDB)
+#if defined(CONFIG_ARCH_LS2080A) || defined(CONFIG_ARCH_LS1088A)
 	gd->arch.sdhc_clk = sys_info.freq_cga_m2;
 #endif
 #else
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [U-Boot] [PATCH] armv8: fsl-lsch3: convert CONFIG_TARGET_x to CONFIG_ARCH_x
  2019-10-21 23:10 [U-Boot] [PATCH] armv8: fsl-lsch3: convert CONFIG_TARGET_x to CONFIG_ARCH_x Michael Walle
@ 2019-11-11 15:18 ` Priyanka Jain
  0 siblings, 0 replies; 2+ messages in thread
From: Priyanka Jain @ 2019-11-11 15:18 UTC (permalink / raw)
  To: u-boot



>-----Original Message-----
>From: U-Boot <u-boot-bounces@lists.denx.de> On Behalf Of Michael Walle
>Sent: Tuesday, October 22, 2019 4:41 AM
>To: u-boot at lists.denx.de
>Cc: Yinbo Zhu <yinbo.zhu@nxp.com>
>Subject: [U-Boot] [PATCH] armv8: fsl-lsch3: convert CONFIG_TARGET_x to
>CONFIG_ARCH_x
>
>The clocks are not dependent on the target but only on the SoC.
>Therefore, convert the CONFIG_TARGET_x macros to the corresponding
>CONFIG_ARCH_x. This will allow other targets to automatically use the
>common code. Otherwise every new target would have to add itself to the
>"#if defined(CONFIG_TARGET_x) || .." macros.
>
>Signed-off-by: Michael Walle <michael@walle.cc>

Applied to fsl-qoriq master, awaiting upstream.

Thanks
priyankajain

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-11-11 15:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-21 23:10 [U-Boot] [PATCH] armv8: fsl-lsch3: convert CONFIG_TARGET_x to CONFIG_ARCH_x Michael Walle
2019-11-11 15:18 ` Priyanka Jain

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.