From 65b7f8ddcf44a9798bd5cbf938b0bd68b0ff0701 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Zi=C4=99cik?= Date: Thu, 11 Apr 2019 14:28:52 +0200 Subject: [PATCH] soc: snps_arc_iot: Get CPU clock frequency from DTS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The SoC initialization code used system clock frequency as a CPU clock frequency. This commit corrects that by obtaining the needed value from DTS. Signed-off-by: Piotr Zięcik --- soc/arc/snps_arc_iot/soc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soc/arc/snps_arc_iot/soc.c b/soc/arc/snps_arc_iot/soc.c index eb7da7abadeb21..9d7ba6c05e0d7c 100644 --- a/soc/arc/snps_arc_iot/soc.c +++ b/soc/arc/snps_arc_iot/soc.c @@ -19,7 +19,7 @@ static int arc_iot_init(struct device *dev) ARG_UNUSED(dev); if (arc_iot_pll_fout_config( - CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC / 1000000) < 0) { + DT_SNPS_ARCEM_0_CLOCK_FREQUENCY / 1000000) < 0) { return -1; }