projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
remove "static" from "ide_dev_desc" to use it from external code
[oweals/u-boot.git]
/
lib_generic
/
bzlib_decompress.c
diff --git
a/lib_generic/bzlib_decompress.c
b/lib_generic/bzlib_decompress.c
index a4a16879e7dce16a970cac52d1bd5ce4208ba230..a5750520cc40487d20430d60c11dac0a9f5076c0 100644
(file)
--- a/
lib_generic/bzlib_decompress.c
+++ b/
lib_generic/bzlib_decompress.c
@@
-1,4
+1,6
@@
#include <config.h>
#include <config.h>
+#include <common.h>
+#include <watchdog.h>
#ifdef CONFIG_BZIP2
/*-------------------------------------------------------------*/
#ifdef CONFIG_BZIP2
/*-------------------------------------------------------------*/
@@
-416,6
+418,9
@@
Int32 BZ2_decompress ( DState* s )
while (True) {
while (True) {
+#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
+ WATCHDOG_RESET();
+#endif
if (nextSym == EOB) break;
if (nextSym == BZ_RUNA || nextSym == BZ_RUNB) {
if (nextSym == EOB) break;
if (nextSym == BZ_RUNA || nextSym == BZ_RUNB) {
@@
-498,6
+503,9
@@
Int32 BZ2_decompress ( DState* s )
if (s->mtfbase[0] == 0) {
kk = MTFA_SIZE-1;
for (ii = 256 / MTFL_SIZE-1; ii >= 0; ii--) {
if (s->mtfbase[0] == 0) {
kk = MTFA_SIZE-1;
for (ii = 256 / MTFL_SIZE-1; ii >= 0; ii--) {
+#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
+ WATCHDOG_RESET();
+#endif
for (jj = MTFL_SIZE-1; jj >= 0; jj--) {
s->mtfa[kk] = s->mtfa[s->mtfbase[ii] + jj];
kk--;
for (jj = MTFL_SIZE-1; jj >= 0; jj--) {
s->mtfa[kk] = s->mtfa[s->mtfbase[ii] + jj];
kk--;
@@
-560,6
+568,9
@@
Int32 BZ2_decompress ( DState* s )
}
while (i != s->origPtr);
}
while (i != s->origPtr);
+#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
+ WATCHDOG_RESET();
+#endif
s->tPos = s->origPtr;
s->nblock_used = 0;
if (s->blockRandomised) {
s->tPos = s->origPtr;
s->nblock_used = 0;
if (s->blockRandomised) {
@@
-572,6
+583,9
@@
Int32 BZ2_decompress ( DState* s )
} else {
} else {
+#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
+ WATCHDOG_RESET();
+#endif
/*-- compute the T^(-1) vector --*/
for (i = 0; i < nblock; i++) {
uc = (UChar)(s->tt[i] & 0xff);
/*-- compute the T^(-1) vector --*/
for (i = 0; i < nblock; i++) {
uc = (UChar)(s->tt[i] & 0xff);