X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=board%2Fcssi%2FMCR3000%2FMCR3000.c;h=570e846a21b74b67b4dcd848e1ec0b5a79d81b84;hb=c27178ba3649f539c9f1890ea147f4c5415f63b5;hp=6939a2cf6179e341104f3b37e7c6c729ea3aee13;hpb=b3ede3317038abdd75c88f20d9b9685ab062b48a;p=oweals%2Fu-boot.git diff --git a/board/cssi/MCR3000/MCR3000.c b/board/cssi/MCR3000/MCR3000.c index 6939a2cf61..570e846a21 100644 --- a/board/cssi/MCR3000/MCR3000.c +++ b/board/cssi/MCR3000/MCR3000.c @@ -1,18 +1,23 @@ +// SPDX-License-Identifier: GPL-2.0+ /* * Copyright (C) 2010-2017 CS Systemes d'Information * Florent Trinh Thai * Christophe Leroy * * Board specific routines for the MCR3000 board - * - * SPDX-License-Identifier: GPL-2.0+ */ #include +#include #include +#include #include #include +#include #include +#include +#include +#include DECLARE_GLOBAL_DATA_PTR; @@ -144,3 +149,17 @@ int board_early_init_f(void) return 0; } + +int board_early_init_r(void) +{ + struct udevice *watchdog_dev = NULL; + + if (uclass_get_device(UCLASS_WDT, 0, &watchdog_dev)) { + puts("Cannot find watchdog!\n"); + } else { + puts("Enabling watchdog.\n"); + wdt_start(watchdog_dev, 0xffff, 0); + } + + return 0; +}