[U-Boot] [PATCH] watchdog petting during autoboot delay

Nicolas Ferre nicolas.ferre at atmel.com
Wed May 26 12:34:49 CEST 2010


Watchdog resets were experienced during autoboot delay. Petting the watchdog
during abortboot() function solve the issue.

Signed-off-by: Nicolas Ferre <nicolas.ferre at atmel.com>
---
 common/main.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/common/main.c b/common/main.c
index f7e7c1c..ea040aa 100644
--- a/common/main.c
+++ b/common/main.c
@@ -159,6 +159,7 @@ static __inline__ int abortboot(int bootdelay)
 	 * when catch up.
 	 */
 	do {
+		WATCHDOG_RESET();	/* Trigger watchdog, if needed */
 		if (tstc()) {
 			if (presskey_len < presskey_max) {
 				presskey [presskey_len ++] = getc();
@@ -251,6 +252,7 @@ static __inline__ int abortboot(int bootdelay)
 # endif
 				break;
 			}
+			WATCHDOG_RESET();	/* Trigger watchdog, if needed */
 			udelay(10000);
 		}
 
-- 
1.5.6.5



More information about the U-Boot mailing list