From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Ferre Date: Thu, 03 Jun 2010 19:27:47 +0200 Subject: [U-Boot] [PATCH] watchdog petting during autoboot delay In-Reply-To: <201005261413.22106.vapier@gentoo.org> References: <1274870089-16974-1-git-send-email-nicolas.ferre@atmel.com> <201005261413.22106.vapier@gentoo.org> Message-ID: <4C07E613.6060409@atmel.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Le 26/05/2010 20:13, Mike Frysinger : > On Wednesday 26 May 2010 06:34:49 Nicolas Ferre wrote: >> --- 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); >> } > > if your udelay() implementation isnt calling WATCHDOG_RESET(), it is broken. > yes, this is undocumented, but search the mailing archives for examples. Yes, for sure, udelay() is calling WATCHDOG_RESET(). > i believe the same goes for serial devices and their tstc() function. True, this is where the problem resides. I will try to modify the atmel_serial tstc() function. Best regards, -- Nicolas Ferre