zlib: updated to v.1.2.3
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH v3 1/1 zlib: updated to v.1.2.3
Quoted 2 lines
Please, is there somebody that can test this patch on a differen arch than PPC?
Arm: success.
tornado% git log --pretty=oneline | head -1 b201171f2b4d509f3ad510b214bee70ff902e3d6 zlib: updated to v.1.2.3
U-Boot 2009.06-00494-gb201171 (Jul 27 2009 - 17:05:15)
[...]
## Booting kernel from Legacy Image at 01308000 ...
Image Name: Linux-2.6.31-rc3
Image Type: ARM Linux Kernel Image (gzip compressed)
Data Size: 1706717 Bytes = 1.6 MB
Load Address: 00008000
Entry Point: 00008000
Uncompressing Kernel Image ...OK
/alessandro
PATCH v3 1/1 zlib: updated to v.1.2.3
Quoted 2 lines · On Monday 27 July 2009 17:09:28 Alessandro Rubini wrote:
Quoted 2 lines
Please, is there somebody that can test this patch on a differen arch than PPC?
I just noticed a common difference in the failing uncompression's. Load address is 0x0 in this case. Perhaps you could give this a try on your system as well (if possible).
I'll try to uncompress to something != 0 tomorrow on PPC.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 zlib: allow 0 as destination pointer
The entry point of an image can be 0 (like on PowerPC), so allow next_out to be NULL in inflate()
---
Stefan Roese:
Quoted 1 line
I'll try to uncompress to something != 0 tomorrow on PPC.
You are right. I naively thought my arm has RAM at 0 like PPC, but entry point of image is not really 0.
lib_generic/zlib.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
lib_generic/zlib.c +1 -1
@@ -1365,7 +1365,7 @@ int flush;static const unsigned short order[19 ] =/* permutation of code lengths */ {16 ,17 ,18 ,0 ,8 ,7 ,9 ,6 ,10 ,5 ,11 ,4 ,12 ,3 ,13 ,2 ,14 ,1 ,15 }; -if (strm ==Z_NULL || strm->state ==Z_NULL || strm->next_out ==Z_NULL || +if (strm ==Z_NULL || strm->state ==Z_NULL || (strm->next_in ==Z_NULL && strm->avail_in !=0 ))return Z_STREAM_ERROR ;
Signature · 1 line
1.5.6.5
PATCH 1/1 zlib: allow 0 as destination pointer
Quoted 2 lines · Alessandro Rubini
The entry point of an image can be 0 (like on PowerPC), so allow
next_outto be NULL ininflate()
Hi,
this patch solves the inflate() error but now a watchdog reset is triggered during decompression:
## Booting kernel from Legacy Image at 00200000 ...
Image Name: Linux-2.4.37.2-dbox2 Image Type: PowerPC Linux Kernel Image (gzip compressed) Data Size: 772042 Bytes = 753.9 kB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
Uncompressing Kernel Image ...
debug: DDF: Calibrating delay loop...
debug: DDF: 66.76 BogoMIPS
debug: WATCHDOG RESET
[...]
The neither the old nor the new code incorporate WATCHDOG_RESET() so the new code seems to be slower than the old one which works. I have yet to dig through the zlib code to insert some WATCHDOG_RESET() here and there like I did with the LZMA code.
Cheers, rhabarber1848
PATCH 1/1 zlib: allow 0 as destination pointer
Dear rhabarber1848,
Quoted 3 lines · In message <[email protected]> you wrote:
this patch solves the
inflate()error but now a watchdog reset is triggered during decompression:
...
Quoted 1 line
The neither the old nor the new code incorporate
WATCHDOG_RESET()so the new
You are wrong. The urrent code installs WATCHDOG_RESET as s.outcb() callback; see function zunzip() in "lib_generic/gunzip.c".
Quoted 3 lines
code seems to be slower than the old one which works. I have yet to dig through the zlib code to insert some
WATCHDOG_RESET()here and there like I did with the LZMA code.
I think this is the wrong thing to do. Use the provided callback instead.
I wonder why you do not create a patch between the old original version and what wd have in U-Boot now (which should clearly show what has been changed to adapt this code for U-Boot), and then apply (if necessary, manually) that patch to the current version?
Best regards,
Wolfgang Denk
Signature · 7 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de "You ain't experienced..." "Well, nor are you." "That's true. But the point is ... the point is ... the point is we've been not experienced for a lot longer than you. We've got a lot of experience of not having any experience." - Terry Pratchett, _Witches Abroad_
PATCH 1/1 zlib: allow 0 as destination pointer
Quoted 4 lines · Wolfgang Denk
I wonder why you do not create a patch between the old original version and what wd have in U-Boot now (which should clearly show what has been changed to adapt this code for U-Boot), and then apply (if necessary, manually) that patch to the current version?
Hi Wolfgang,
I did exactly that, I took rc1, downloaded the zlib-1.2.3 patch from the newsgroup[1] and added the patch by Alessandro[2]. The WATCHDOG_RESET code in gunzip.c is not touched by either patches, but I still get a WATCHDOG_RESET when the kernel image is decompressed with the new code.
Though is seems that
if (z->outcb != Z_NULL)
(*z->outcb)(Z_NULL, 0);
is not used anymore in zlib.c so the WATCHDOG_RESET calls are silently ignored. I will try to re-add them tomorrow.
Besides this, rc1 is working fine here.
Cheers, rhabarber1848
[1] http://article.gmane.org/gmane.comp.boot-loaders.u-boot/64727
[2] http://article.gmane.org/gmane.comp.boot-loaders.u-boot/64969
PATCH 1/1 zlib: allow 0 as destination pointer
Dear rhabarber1848,
Quoted 8 lines · In message <[email protected]> you wrote:
Though is seems that
if (
z->outcb!=Z_NULL)(*z->outcb)(Z_NULL, 0);is not used anymore in
zlib.cso theWATCHDOG_RESETcalls are silently ignored. I will try to re-add them tomorrow.
I see.
Quoted 1 line
Besides this, rc1 is working fine here.
Thanks for the confirmation.
Best regards,
Wolfgang Denk
Signature · 7 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"Pardon me for breathing, which I never do anyway so I don't know why
I bother to say it, oh God, I'm so depressed. Here's another of those
self-satisfied doors. Life! Don't talk to me about life."
- Marvin the Paranoid AndroidPATCH 1/1 zlib: allow 0 as destination pointer
In reply to Alessandro RubiniQuoted 11 lines · On Monday 27 July 2009 18:40:31 Alessandro Rubini wrote:
The entry point of an image can be 0 (like on PowerPC), so allow
next_outto be NULL ininflate()Signed-off-by Alessandro Rubini <[email protected]>---
Stefan Roese:
Quoted 1 line
I'll try to uncompress to something != 0 tomorrow on PPC.
You are right. I naively thought my arm has RAM at 0 like PPC, but entry point of image is not really 0.
Yes, this works:
Thanks.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 zlib: allow 0 as destination pointer
Very good!!!
So is it time to re-apply zlib patch to u-boot main tree, together Alessandro's patch?
Wolfgang, what's your position?
Best Regards,
Giuseppe
-----Original Message-----
From: [email protected] [mailto:u-boot-bounces at lists.denx.de] On Behalf Of Stefan Roese
Sent: Tuesday, July 28, 2009 8:31 AM
To: Alessandro Rubini
Cc: u-boot at lists.denx.de; rhabarber1848 at web.de
Subject: Re: [U-Boot] [PATCH] zlib: allow 0 as destination pointer
Quoted 11 lines · On Monday 27 July 2009 18:40:31 Alessandro Rubini wrote:
The entry point of an image can be 0 (like on PowerPC), so allow
next_outto be NULL ininflate()Signed-off-by Alessandro Rubini <[email protected]>---
Stefan Roese:
Quoted 1 line
I'll try to uncompress to something != 0 tomorrow on PPC.
You are right. I naively thought my arm has RAM at 0 like PPC, but entry point of image is not really 0.
Yes, this works:
Thanks.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot
PATCH 1/1 zlib: allow 0 as destination pointer
Dear Giuseppe CONDORELLI,
Quoted 5 lines · In message <[email protected]> you wrote:
Very good!!!
So is it time to re-apply zlib patch to u-boot main tree, together Alessandro's patch?Wolfgang, what's your position?
Actually I'm waiting for a new patch that integrates that fix.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Just about every computer on the market today runs Unix, except the Mac (and nobody cares about it). - Bill Joy 6/21/85
PATCH 1/1 zlib: allow 0 as destination pointer
Dear Wolfgang,
Quoted 1 line
Actually I'm waiting for a new patch that integrates that fix.
Maybe I've not understood.
Do you mean you are waiting a new zlib patch [v4] that includes Alessandro's patch, to apply
only one patch containing all?
Best Regards,
Giuseppe
-----Original Message-----
From: Wolfgang Denk [mailto:wd at denx.de]
Sent: Wednesday, July 29, 2009 8:24 AM
To: Giuseppe CONDORELLI
Cc: u-boot at lists.denx.de
Subject: Re: [U-Boot] [PATCH] zlib: allow 0 as destination pointer
Dear Giuseppe CONDORELLI,
Quoted 5 lines · In message <[email protected]> you wrote:
Very good!!!
So is it time to re-apply zlib patch to u-boot main tree, together Alessandro's patch?Wolfgang, what's your position?
Actually I'm waiting for a new patch that integrates that fix.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Just about every computer on the market today runs Unix, except the Mac (and nobody cares about it). - Bill Joy 6/21/85
PATCH 1/1 zlib: allow 0 as destination pointer
Dear Giuseppe CONDORELLI,
Quoted 6 lines · In message <[email protected]> you wrote:
Quoted 2 lines
Actually I'm waiting for a new patch that integrates that fix.
Maybe I've not understood.
Do you mean you are waiting a new zlib patch [v4] that includes Alessandro's patch, to apply
only one patch containing all?
Yes. It makes no sense to add a known to be broken patch and fix it in a second commit, as this leaves only a state in the tree where attempts to bisect any issues run into problems. So please submit a new, fixed patch, that really works.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Applying computer technology is simply finding the right wrench to pound in the correct screw.
PATCH 1/1 zlib: allow 0 as destination pointer
In reply to Wolfgang DenkQuoted 10 lines · Wolfgang Denk
Dear Giuseppe CONDORELLI,
Quoted 5 lines · In message <[email protected]> you wrote:
Very good!!!
So is it time to re-apply zlib patch to u-boot main tree, together Alessandro's patch?Wolfgang, what's your position?
Actually I'm waiting for a new patch that integrates that fix.
Hi,
please do not commit the zlib-1.2.3 patch in its current state, although Alessandro's patch fixes on bug there is still the problem that the WATCHDOG_RESET() calls from gunzip.c
#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG)
s.outcb = (cb_func)WATCHDOG_RESET;
#else
s.outcb = Z_NULL;#endif<>/* CONFIG_HW_WATCHDOG */
are silently ignored in the new zlib code. My C knowledge is insufficient to solve this problem. In its current state it will break zlib decompression on the machines I am taking care of.
Cheers, rhabarber1848
PATCH 1/1 zlib: allow 0 as destination pointer
Dear rhabarber1848,
Quoted 11 lines · In message <[email protected]> you wrote:
Quoted 2 lines
Actually I'm waiting for a new patch that integrates that fix.
please do not commit the zlib-1.2.3 patch in its current state, although Alessandro's patch fixes on bug there is still the problem that the
WATCHDOG_RESET()calls fromgunzip.c#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG) s.outcb = (cb_func)WATCHDOG_RESET; #else s.outcb = Z_NULL;
Quoted 5 lines
#endif<>/*
CONFIG_HW_WATCHDOG*/are silently ignored in the new zlib code. My C knowledge is insufficient to solve this problem. In its current state it will break zlib decompression on the machines I am taking care of.
Agreed - that should be working, too, before we pull that patch into mainline.
Best regards,
Wolfgang Denk
Signature · 6 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Perfection is reached, not when there is no longer anything to add,
but when there is no longer anything to take away.
- Antoine de Saint-ExuperyPATCH 1/1 zlib: allow 0 as destination pointer
Hi rhabarber1848,
please could you test latest two zlib patches I have sent few minutes ago?
NOTE: the first one is waiting for approval due to its big size.
Thanks, I hope these patches will solve your issue.
G.
-----Original Message-----
From: [email protected] [mailto:u-boot-bounces at lists.denx.de] On Behalf Of Wolfgang Denk
Sent: Wednesday, July 29, 2009 9:12 AM
To: rhabarber1848 at web.de
Cc: u-boot at lists.denx.de
Subject: Re: [U-Boot] [PATCH] zlib: allow 0 as destination pointer
Dear rhabarber1848,
Quoted 7 lines · In message <[email protected]> you wrote:
Quoted 2 lines
Actually I'm waiting for a new patch that integrates that fix.
please do not commit the zlib-1.2.3 patch in its current state, although Alessandro's patch fixes on bug there is still the problem that the
WATCHDOG_RESET()calls fromgunzip.c
Quoted 7 lines
#if defined(CONFIG_HW_WATCHDOG) || defined(CONFIG_WATCHDOG) s.outcb = (cb_func)WATCHDOG_RESET; #else s.outcb = Z_NULL;#endif<>/*
CONFIG_HW_WATCHDOG*/are silently ignored in the new zlib code. My C knowledge is insufficient
to
Quoted 2 lines
solve this problem. In its current state it will break zlib decompression on the machines I am taking care of.
Agreed - that should be working, too, before we pull that patch into mainline.
Best regards,
Wolfgang Denk
Signature · 10 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Perfection is reached, not when there is no longer anything to add,
but when there is no longer anything to take away.
- Antoine de Saint-Exupery
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot