[PATCH u-boot v2016.07] aspeed: clear all asserting watchdog conditions

Milton Miller II miltonm at us.ibm.com
Thu Sep 28 11:54:36 AEST 2017


On 09/27/2017 around 04:27PM in some time zone, Christopher Bostic wrote:
>Clear out all flagged watchdog conditions to allow the following
>kernel load to complete successfully.  This will allow the kernel
>to determine the next boot side instead of leaving it to u-boot.
>This method of side switching has been suggested by Milton Miller
>and Adirana Kobylak.

I'm not immediately sure what the SCU3C write is about, but we
can't do the others in u-boot as we need to continue to access
the secondary flash during u-boot.

I was suggesting we clear the watchdog alt-boot overrides when
we start the linux kernel so that the kernel chip selects match
the hardware, while allowing the alternate u-boot to continue
to read from the chip its started out of.

I'll work more urgently on drafting a more detailed proposal.

>
>Signed-off-by: Christopher Bostic <cbostic at linux.vnet.ibm.com>
>---
> arch/arm/mach-aspeed/reset.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
>diff --git a/arch/arm/mach-aspeed/reset.c
>b/arch/arm/mach-aspeed/reset.c
>index 1a44b3a..7d88d99 100644
>--- a/arch/arm/mach-aspeed/reset.c
>+++ b/arch/arm/mach-aspeed/reset.c
>@@ -9,6 +9,12 @@
> 
> void reset_cpu(ulong addr)
> {
>+	/* Clear out all flagged watchdog events */
>+	__raw_writel(0x1, AST_WDT1_BASE+0x14);
>+	__raw_writel(0x1, AST_WDT2_BASE+0x14);
>+	__raw_writel(0x1, AST_WDT3_BASE+0x14);
>+	__raw_writel(__raw_readl(AST_SCU_BASE+0x3C) & 0x03,
>AST_SCU_BASE+0x3C);
>+
> 	__raw_writel(0x10 , AST_WDT1_BASE+0x04);
> 	__raw_writel(0x4755, AST_WDT1_BASE+0x08);
> 	__raw_writel(0x3, AST_WDT1_BASE+0x0c);
>-- 
>1.8.2.2
>
>



More information about the openbmc mailing list