Hi Martin,

On 1/16/23 06:20, Martin Rowe wrote:
Tony,

Did you build this clearfog board as is? i.e. did you make any change
in the clearfog_defconfig?

clearfog_defconfig with:
CONFIG_MVEBU_SPL_BOOT_DEVICE_SATA=y
CONFIG_SPL_SATA=y

Plus a dts patch to sdhci@d8000 to make it work for eMMC (swap
cd-gpios for non-removable)
Plus a workaround that's not yet merged for a build failure with SATA from [1]

Shouldn't be anything that affects the timer, but I can try a fully
clean build with the defconfig if you need it.

No need for this.

Could you please test with this attached patch, if this fixes this issue
on your clearfog?

Thanks,
Stefan
From 9ba26205434f2406d6c8a5dd30e1c065185748d0 Mon Sep 17 00:00:00 2001
From: Stefan Roese <s...@denx.de>
Date: Mon, 16 Jan 2023 09:01:48 +0100
Subject: [PATCH] timer: orion-timer: Fix problem in early_init_done()

todo

Signed-off-by: Stefan Roese <s...@denx.de>
---
 drivers/timer/orion-timer.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/timer/orion-timer.c b/drivers/timer/orion-timer.c
index 810a03d54960..9cab27f2e48b 100644
--- a/drivers/timer/orion-timer.c
+++ b/drivers/timer/orion-timer.c
@@ -25,7 +25,8 @@ struct orion_timer_priv {
 
 static bool early_init_done(void *base)
 {
-	if (readl(base + TIMER_CTRL) & TIMER0_EN)
+	if ((readl(base + TIMER_CTRL) & TIMER0_EN) &&
+	    (readl(base + TIMER0_RELOAD) == ~0))
 		return true;
 	return false;
 }
-- 
2.39.0

Reply via email to