public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] zlib: Add further watchdog reset calls
@ 2010-08-31 17:11 Stefan Roese
  2010-09-02 16:40 ` Detlev Zundel
  2010-09-09 18:27 ` Wolfgang Denk
  0 siblings, 2 replies; 7+ messages in thread
From: Stefan Roese @ 2010-08-31 17:11 UTC (permalink / raw)
  To: u-boot

Patch 253cb831 [zlib: add watchdog reset call] added already a few
watchdog reset calls to the new zlib U-Boot port. But on some boards
this is not enough. Additional calls are needed on boards with
short watchdog timeouts.

This was detected and tested on the lwmon5 board with a very short
watchdog timeout. Without this patch, the board resets during Linux
kernel decompression. With it, the decompression succeeds.

Signed-off-by: Stefan Roese <sr@denx.de>
---
 lib/zlib.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/lib/zlib.c b/lib/zlib.c
index 26e5af1..39d5dab 100644
--- a/lib/zlib.c
+++ b/lib/zlib.c
@@ -1599,6 +1599,8 @@ int flush;
             strm->adler = state->check = adler32(0L, Z_NULL, 0);
             state->mode = TYPE;
         case TYPE:
+	    if (strm->outcb != Z_NULL)
+		    (*strm->outcb)(Z_NULL, 0); /* call WATCHDOG_RESET */
             if (flush == Z_BLOCK) goto inf_leave;
         case TYPEDO:
             if (state->last) {
-- 
1.7.2.2

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-09-13  9:28 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-31 17:11 [U-Boot] [PATCH] zlib: Add further watchdog reset calls Stefan Roese
2010-09-02 16:40 ` Detlev Zundel
2010-09-03  7:10   ` Stefan Roese
2010-09-03  8:30     ` Wolfgang Denk
2010-09-03 11:37       ` Stefan Roese
2010-09-09 18:27 ` Wolfgang Denk
2010-09-13  9:28   ` Stefan Roese

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox