Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-28 Thread Lei Wen
Hi Tom,


  If the patch is generally accepted, I would update with another
  version with the README update included.

 Yes, please v2 things with an updated README.  Thanks.


I have updated the patch set, please help re-check it.

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-27 Thread Tom Rini
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 09/26/12 19:05, Lei Wen wrote:
 Hi Tom,
 
 On Thu, Sep 27, 2012 at 12:20 AM, Tom Rini tr...@ti.com 
 mailto:tr...@ti.com wrote:
 
 On Wed, Sep 26, 2012 at 05:34:25PM +0200, Marek Vasut wrote:
 Dear Lei Wen,
 
 On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de
 mailto:ma...@denx.de wrote:
 Dear Lukasz Majewski,
 
 [...]
 
 Ok, that means we can make use of this command ?
 
 I cannot promise, that I will provide the zip support
 straightaway in
 the DFU.
 
 On the one hand if DFU is the only user of this command we
 are adding
 in fact a dead code. On the other hand we can use proper
 #define CONFIG_CMD_ZIP
 to not
 compile it until we really use this.
 
 I'd rather see a user and code added, not the other way.
 
 common/cmd_zip.c is another user. :)
 
 I'm OK with this one.
 
 And file systems could use the zip callback to directly create
 the zipped
 file.
 
 Definitelly not ... zip callback for FS is wrong.
 
 Since current ext4 and fat in uboot support write function, I
 think it
 could be a potential feature to add.
 
 cmd_zip + fs write call is OK. But why do we need to zip
 anything
 in uboot,
 what's the usecase?
 
 
 Are there any other potential users of this functionality
 (ZIP compression/decompression) in u-boot?
 
 None that I know of. Is it really zip or is it gzip ?
 
 It is porting from zlib, and is there any different for the
 compression
 side for zip and gzip?
 
 I ain't no expert, so I'm asking
 
 This patch is pending for too long time, do we have a answer
 now
 whether
 it could be merged?
 
 Ccing Tom
 
 I am fine, conceptually.  I see a few needed changes /
 clarifications: - Is this zip or gzip compression in the exposed
 command?
 
 
 Sure, the zip command is exposed. U_BOOT_CMD( zip,5,  1,
 do_zip, zip a memory region, srcaddr srcsize dstaddr [dstsize] 
 );
 
 
 - You don't update README with CONFIG_CMD_ZIP
 
 
 If the patch is generally accepted, I would update with another 
 version with the README update included.

Yes, please v2 things with an updated README.  Thanks.

- -- 
Tom
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://www.enigmail.net/

iQIcBAEBAgAGBQJQZG8nAAoJENk4IS6UOR1W7eoP/R60nMqBgykTmLt/zuSCaFNw
x+wHnfsQBUIJyFVnwds/343D6kfW+KIGXjxAT8ILecL62g0H9/3lFiC6EhJzxzJY
HjAv9SLPHtUzTFSul+sjD3rG5v5cnwiU8XOe5Fdp1hfRTjiFPU8/4Qa4NpUQ227K
Wxt7+oA6cZkFg2wo9GSJscV3DSrSLHm2ctnrz2txKY4kO41VGjIE27tAgllRUC3r
7QdhZWgePGQIJDUL9q9UzgUEFB7FzFs7CqDQS5DgAOmhlrD8ZoXDX/B8y7u+nYCI
4Q5cHT2FMwfxs12bWLL4xO63bOLhXrTpZ3vD5un4kyfjup2p7qdiCzz5oYnLFtz0
th64scs6GKpczBspdoKaLf+ostcjQwe68/g7N6+nCGneQ2cpSpbQKWK7OOUZLCeC
PiRgHllUz6dnHUAkCSr08qbNmvpEQzG9xLw5m0Cr9ZQ4Miw4cuI9T7/u8Kg6/YYQ
w4MslhC/ZNO9EPUiF5eWiuynXjb5peWdaN9YsqVzWlCuT0v9Ig4AtzyNPRy2ThBc
MB/6ckhOjG67p52slgQdi3wM3X6cLyG5WQHRVGlGEvvvUWA74m7yks7KlWk0LVNV
aVyWKKwU23CIL+MIhHwG4n38zKXRoIu1VuZH1vCG0geBeJkp3Il062ydV07OiG2Q
LZuuPue1ATgn61kGxaUK
=8DlA
-END PGP SIGNATURE-
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-26 Thread Lei Wen
On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de wrote:

 Dear Lukasz Majewski,

 [...]

   Ok, that means we can make use of this command ?
 
  I cannot promise, that I will provide the zip support straightaway in
  the DFU.
 
  On the one hand if DFU is the only user of this command we are adding in
  fact a dead code.
  On the other hand we can use proper #define CONFIG_CMD_ZIP to not
  compile it until we really use this.

 I'd rather see a user and code added, not the other way.


common/cmd_zip.c is another user. :)
And file systems could use the zip callback to directly create the zipped
file.
Since current ext4 and fat in uboot support write function, I think it
could be
a potential feature to add.



  Are there any other potential users of this functionality (ZIP
  compression/decompression) in u-boot?

 None that I know of. Is it really zip or is it gzip ?


It is porting from zlib, and is there any different for the compression
side for
zip and gzip?

This patch is pending for too long time, do we have a answer now whether
it could be merged?

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-26 Thread Marek Vasut
Dear Lei Wen,

 On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de wrote:
  Dear Lukasz Majewski,
  
  [...]
  
Ok, that means we can make use of this command ?
   
   I cannot promise, that I will provide the zip support straightaway in
   the DFU.
   
   On the one hand if DFU is the only user of this command we are adding
   in fact a dead code.
   On the other hand we can use proper #define CONFIG_CMD_ZIP to not
   compile it until we really use this.
  
  I'd rather see a user and code added, not the other way.
 
 common/cmd_zip.c is another user. :)

I'm OK with this one.

 And file systems could use the zip callback to directly create the zipped
 file.

Definitelly not ... zip callback for FS is wrong.

 Since current ext4 and fat in uboot support write function, I think it
 could be
 a potential feature to add.

cmd_zip + fs write call is OK. But why do we need to zip anything in uboot, 
what's the usecase?


   Are there any other potential users of this functionality (ZIP
   compression/decompression) in u-boot?
  
  None that I know of. Is it really zip or is it gzip ?
 
 It is porting from zlib, and is there any different for the compression
 side for
 zip and gzip?

I ain't no expert, so I'm asking

 This patch is pending for too long time, do we have a answer now whether
 it could be merged?

Ccing Tom

 Thanks,
 Lei

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-26 Thread Tom Rini
On Wed, Sep 26, 2012 at 05:34:25PM +0200, Marek Vasut wrote:
 Dear Lei Wen,
 
  On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de wrote:
   Dear Lukasz Majewski,
   
   [...]
   
 Ok, that means we can make use of this command ?

I cannot promise, that I will provide the zip support straightaway in
the DFU.

On the one hand if DFU is the only user of this command we are adding
in fact a dead code.
On the other hand we can use proper #define CONFIG_CMD_ZIP to not
compile it until we really use this.
   
   I'd rather see a user and code added, not the other way.
  
  common/cmd_zip.c is another user. :)
 
 I'm OK with this one.
 
  And file systems could use the zip callback to directly create the zipped
  file.
 
 Definitelly not ... zip callback for FS is wrong.
 
  Since current ext4 and fat in uboot support write function, I think it
  could be
  a potential feature to add.
 
 cmd_zip + fs write call is OK. But why do we need to zip anything in uboot, 
 what's the usecase?
 
 
Are there any other potential users of this functionality (ZIP
compression/decompression) in u-boot?
   
   None that I know of. Is it really zip or is it gzip ?
  
  It is porting from zlib, and is there any different for the compression
  side for
  zip and gzip?
 
 I ain't no expert, so I'm asking
 
  This patch is pending for too long time, do we have a answer now whether
  it could be merged?
 
 Ccing Tom

I am fine, conceptually.  I see a few needed changes / clarifications:
- Is this zip or gzip compression in the exposed command?
- You don't update README with CONFIG_CMD_ZIP

-- 
Tom


signature.asc
Description: Digital signature
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-26 Thread Lei Wen
Hi Tom,

On Thu, Sep 27, 2012 at 12:20 AM, Tom Rini tr...@ti.com wrote:

 On Wed, Sep 26, 2012 at 05:34:25PM +0200, Marek Vasut wrote:
  Dear Lei Wen,
 
   On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de wrote:
Dear Lukasz Majewski,
   
[...]
   
  Ok, that means we can make use of this command ?

 I cannot promise, that I will provide the zip support
 straightaway in
 the DFU.

 On the one hand if DFU is the only user of this command we are
 adding
 in fact a dead code.
 On the other hand we can use proper #define CONFIG_CMD_ZIP to not
 compile it until we really use this.
   
I'd rather see a user and code added, not the other way.
  
   common/cmd_zip.c is another user. :)
 
  I'm OK with this one.
 
   And file systems could use the zip callback to directly create the
 zipped
   file.
 
  Definitelly not ... zip callback for FS is wrong.
 
   Since current ext4 and fat in uboot support write function, I think it
   could be
   a potential feature to add.
 
  cmd_zip + fs write call is OK. But why do we need to zip anything in
 uboot,
  what's the usecase?
 
 
 Are there any other potential users of this functionality (ZIP
 compression/decompression) in u-boot?
   
None that I know of. Is it really zip or is it gzip ?
  
   It is porting from zlib, and is there any different for the compression
   side for
   zip and gzip?
 
  I ain't no expert, so I'm asking
 
   This patch is pending for too long time, do we have a answer now
 whether
   it could be merged?
 
  Ccing Tom

 I am fine, conceptually.  I see a few needed changes / clarifications:
 - Is this zip or gzip compression in the exposed command?


Sure, the zip command is exposed.
U_BOOT_CMD(
zip,5,  1,  do_zip,
zip a memory region,
srcaddr srcsize dstaddr [dstsize]
);


 - You don't update README with CONFIG_CMD_ZIP


If the patch is generally accepted, I would update with another
version with the README update included.

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-26 Thread Lei Wen
Hi Marek,

On Wed, Sep 26, 2012 at 11:34 PM, Marek Vasut ma...@denx.de wrote:

 Dear Lei Wen,

  On Thu, Sep 6, 2012 at 6:49 PM, Marek Vasut ma...@denx.de wrote:
   Dear Lukasz Majewski,
  
   [...]
  
 Ok, that means we can make use of this command ?
   
I cannot promise, that I will provide the zip support straightaway
 in
the DFU.
   
On the one hand if DFU is the only user of this command we are adding
in fact a dead code.
On the other hand we can use proper #define CONFIG_CMD_ZIP to not
compile it until we really use this.
  
   I'd rather see a user and code added, not the other way.
 
  common/cmd_zip.c is another user. :)

 I'm OK with this one.

Nice to hear that.



  And file systems could use the zip callback to directly create the zipped
  file.

 Definitelly not ... zip callback for FS is wrong.


If there is another work around that facilitate write compressed memory into
fs, I also like to take it. Certainly callback is not the only choice.


  Since current ext4 and fat in uboot support write function, I think it
  could be
  a potential feature to add.

 cmd_zip + fs write call is OK. But why do we need to zip anything in uboot,
 what's the usecase?


The use case may come from we need to dump a range of board memory.
While this range tend to be large, and this dump operation behavior may
occur frequently. Then do compression would be a good choice.

It would allow us to do more dump than the non-compression one.




Are there any other potential users of this functionality (ZIP
compression/decompression) in u-boot?
  
   None that I know of. Is it really zip or is it gzip ?
 
  It is porting from zlib, and is there any different for the compression
  side for
  zip and gzip?

 I ain't no expert, so I'm asking


I quote below saying from zlib.net, maybe this could make us understand the
difference. :)
Mark is also the author of gzip's
andUnZiphttp://www.info-zip.org/pub/infozip/UnZip.html's
main decompression routines and was the original author of Zip. Not
surprisingly, the compression algorithm used in zlib is essentially the
same as that in gzip and Zip, namely, the `deflate' method that originated
in PKWARE http://www.pkware.com/'s PKZIP 2.x.

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-06 Thread Marek Vasut
Dear Lei Wen,

 Hi Marek,
 
 On Thu, Sep 6, 2012 at 12:18 PM, Marek Vasut marek.va...@gmail.com wrote:
  Dear adrian.w...@gmail.com,
  
  From: Lei Wen lei...@marvell.com
  
  Lei? Long time no see :)
 
 Long time no see. :)

Yep, you're doing well?

  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib 1.2.5
  without any change. While the third patch did the necessary change to
  make the import file could be built passed in uboot environment.
  
  The fourth patch make us could zip the memory from 0 in the address
  space.
  
  The latter fifth and sixth patch does the adding gzip lib function
  exporting and zip command support.
  
  Patch set test with zipunzip and compared with original memory content.
  
  Lei Wen (6):
lib: zlib: import deflate source file from 1.2.5
lib: zlib: import trees file from 1.2.5
lib: zlib: include deflate into zlib build
lib: zlib: remove the limitation for cannot using 0 as start
lib: add gzip lib function callback
common: add zip command support
   
   common/Makefile   |1 +
   common/cmd_zip.c  |   60 ++
   include/common.h  |7 +
   include/u-boot/zlib.h |   40 +-
   lib/Makefile  |1 +
   lib/gzip.c|  143 
   lib/zlib/deflate.c| 1831
  
  + lib/zlib/deflate.h   
  | 342 +
  
   lib/zlib/trees.c  | 1244 +
   lib/zlib/trees.h  |  128 
   lib/zlib/zlib.c   |8 +
   lib/zlib/zutil.h  |4 +
   12 files changed, 3804 insertions(+), 5 deletions(-)
   create mode 100644 common/cmd_zip.c
   create mode 100644 lib/gzip.c
   create mode 100644 lib/zlib/deflate.c
   create mode 100644 lib/zlib/deflate.h
   create mode 100644 lib/zlib/trees.c
   create mode 100644 lib/zlib/trees.h
  
  Are there any users for this code? What is it for ?
 
 This patch was intended to compress the memory when uploading
 through USB. So that uploaded image could be smaller.
 Maybe there are some other usage, like memory testing?

CCing Lukasz, maybe he can find some use for this in the DFU series?

  Best regards,
  Marek Vasut
 
 Thanks,
 Lei

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-06 Thread Lukasz Majewski
Dear Marek and Lei,

 Dear Lei Wen,
 
  Hi Marek,
  
  On Thu, Sep 6, 2012 at 12:18 PM, Marek Vasut
  marek.va...@gmail.com wrote:
   Dear adrian.w...@gmail.com,
   
   From: Lei Wen lei...@marvell.com
   
   Lei? Long time no see :)
  
  Long time no see. :)
 
 Yep, you're doing well?
 
   This patch set add zip command support for uboot.
   The first two patches import deflate and trees functions from
   zlib 1.2.5 without any change. While the third patch did the
   necessary change to make the import file could be built passed
   in uboot environment.
   
   The fourth patch make us could zip the memory from 0 in the
   address space.
   
   The latter fifth and sixth patch does the adding gzip lib
   function exporting and zip command support.
   
   Patch set test with zipunzip and compared with original memory
   content.
   
   Lei Wen (6):
 lib: zlib: import deflate source file from 1.2.5
 lib: zlib: import trees file from 1.2.5
 lib: zlib: include deflate into zlib build
 lib: zlib: remove the limitation for cannot using 0 as start
 lib: add gzip lib function callback
 common: add zip command support

common/Makefile   |1 +
common/cmd_zip.c  |   60 ++
include/common.h  |7 +
include/u-boot/zlib.h |   40 +-
lib/Makefile  |1 +
lib/gzip.c|  143 
lib/zlib/deflate.c| 1831
   
   +
   lib/zlib/deflate.h | 342 +
   
lib/zlib/trees.c  | 1244 +
lib/zlib/trees.h  |  128 
lib/zlib/zlib.c   |8 +
lib/zlib/zutil.h  |4 +
12 files changed, 3804 insertions(+), 5 deletions(-)
create mode 100644 common/cmd_zip.c
create mode 100644 lib/gzip.c
create mode 100644 lib/zlib/deflate.c
create mode 100644 lib/zlib/deflate.h
create mode 100644 lib/zlib/trees.c
create mode 100644 lib/zlib/trees.h
   
   Are there any users for this code? What is it for ?
  
  This patch was intended to compress the memory when uploading
  through USB. So that uploaded image could be smaller.
  Maybe there are some other usage, like memory testing?
 
 CCing Lukasz, maybe he can find some use for this in the DFU series?
 

I think, that there is a possibility to gzip the host DFU data and
uncompress it after USB transmission (especially when zip command is
available from command line).

   Best regards,
   Marek Vasut
  
  Thanks,
  Lei
 
 Best regards,
 Marek Vasut


-- 
Best regards,

Lukasz Majewski

Samsung Poland RD Center | Linux Platform Group
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-06 Thread Marek Vasut
Dear Lukasz Majewski,

 Dear Marek and Lei,
 
  Dear Lei Wen,
  
   Hi Marek,
   
   On Thu, Sep 6, 2012 at 12:18 PM, Marek Vasut
   
   marek.va...@gmail.com wrote:
Dear adrian.w...@gmail.com,

From: Lei Wen lei...@marvell.com

Lei? Long time no see :)
   
   Long time no see. :)
  
  Yep, you're doing well?
  
This patch set add zip command support for uboot.
The first two patches import deflate and trees functions from
zlib 1.2.5 without any change. While the third patch did the
necessary change to make the import file could be built passed
in uboot environment.

The fourth patch make us could zip the memory from 0 in the
address space.

The latter fifth and sixth patch does the adding gzip lib
function exporting and zip command support.

Patch set test with zipunzip and compared with original memory
content.

Lei Wen (6):
  lib: zlib: import deflate source file from 1.2.5
  lib: zlib: import trees file from 1.2.5
  lib: zlib: include deflate into zlib build
  lib: zlib: remove the limitation for cannot using 0 as start
  lib: add gzip lib function callback
  common: add zip command support
 
 common/Makefile   |1 +
 common/cmd_zip.c  |   60 ++
 include/common.h  |7 +
 include/u-boot/zlib.h |   40 +-
 lib/Makefile  |1 +
 lib/gzip.c|  143 
 lib/zlib/deflate.c| 1831

+
lib/zlib/deflate.h | 342 +

 lib/zlib/trees.c  | 1244 +
 lib/zlib/trees.h  |  128 
 lib/zlib/zlib.c   |8 +
 lib/zlib/zutil.h  |4 +
 12 files changed, 3804 insertions(+), 5 deletions(-)
 create mode 100644 common/cmd_zip.c
 create mode 100644 lib/gzip.c
 create mode 100644 lib/zlib/deflate.c
 create mode 100644 lib/zlib/deflate.h
 create mode 100644 lib/zlib/trees.c
 create mode 100644 lib/zlib/trees.h

Are there any users for this code? What is it for ?
   
   This patch was intended to compress the memory when uploading
   through USB. So that uploaded image could be smaller.
   Maybe there are some other usage, like memory testing?
  
  CCing Lukasz, maybe he can find some use for this in the DFU series?
 
 I think, that there is a possibility to gzip the host DFU data and
 uncompress it after USB transmission (especially when zip command is
 available from command line).

Ok, that means we can make use of this command ?
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-06 Thread Lukasz Majewski
Hi Marek,

 Dear Lukasz Majewski,
 
  Dear Marek and Lei,
  
   Dear Lei Wen,
   
Hi Marek,

On Thu, Sep 6, 2012 at 12:18 PM, Marek Vasut

marek.va...@gmail.com wrote:
 Dear adrian.w...@gmail.com,
 
 From: Lei Wen lei...@marvell.com
 
 Lei? Long time no see :)

Long time no see. :)
   
   Yep, you're doing well?
   
 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from
 zlib 1.2.5 without any change. While the third patch did the
 necessary change to make the import file could be built
 passed in uboot environment.
 
 The fourth patch make us could zip the memory from 0 in the
 address space.
 
 The latter fifth and sixth patch does the adding gzip lib
 function exporting and zip command support.
 
 Patch set test with zipunzip and compared with original
 memory content.
 
 Lei Wen (6):
   lib: zlib: import deflate source file from 1.2.5
   lib: zlib: import trees file from 1.2.5
   lib: zlib: include deflate into zlib build
   lib: zlib: remove the limitation for cannot using 0 as
 start lib: add gzip lib function callback
   common: add zip command support
  
  common/Makefile   |1 +
  common/cmd_zip.c  |   60 ++
  include/common.h  |7 +
  include/u-boot/zlib.h |   40 +-
  lib/Makefile  |1 +
  lib/gzip.c|  143 
  lib/zlib/deflate.c| 1831
 
 +
 lib/zlib/deflate.h | 342 +
 
  lib/zlib/trees.c  | 1244
 + lib/zlib/trees.h  |
 128  lib/zlib/zlib.c   |8 +
  lib/zlib/zutil.h  |4 +
  12 files changed, 3804 insertions(+), 5 deletions(-)
  create mode 100644 common/cmd_zip.c
  create mode 100644 lib/gzip.c
  create mode 100644 lib/zlib/deflate.c
  create mode 100644 lib/zlib/deflate.h
  create mode 100644 lib/zlib/trees.c
  create mode 100644 lib/zlib/trees.h
 
 Are there any users for this code? What is it for ?

This patch was intended to compress the memory when uploading
through USB. So that uploaded image could be smaller.
Maybe there are some other usage, like memory testing?
   
   CCing Lukasz, maybe he can find some use for this in the DFU
   series?
  
  I think, that there is a possibility to gzip the host DFU data and
  uncompress it after USB transmission (especially when zip command
  is available from command line).
 
 Ok, that means we can make use of this command ?

I cannot promise, that I will provide the zip support straightaway in
the DFU.

On the one hand if DFU is the only user of this command we are adding in
fact a dead code.
On the other hand we can use proper #define CONFIG_CMD_ZIP to not
compile it until we really use this.

Are there any other potential users of this functionality (ZIP
compression/decompression) in u-boot?

-- 
Best regards,

Lukasz Majewski

Samsung Poland RD Center | Linux Platform Group
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-06 Thread Marek Vasut
Dear Lukasz Majewski,

[...]

  Ok, that means we can make use of this command ?
 
 I cannot promise, that I will provide the zip support straightaway in
 the DFU.
 
 On the one hand if DFU is the only user of this command we are adding in
 fact a dead code.
 On the other hand we can use proper #define CONFIG_CMD_ZIP to not
 compile it until we really use this.

I'd rather see a user and code added, not the other way.

 Are there any other potential users of this functionality (ZIP
 compression/decompression) in u-boot?

None that I know of. Is it really zip or is it gzip ?

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-05 Thread Marek Vasut
Dear adrian.w...@gmail.com,

 From: Lei Wen lei...@marvell.com

Lei? Long time no see :)

 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from zlib 1.2.5
 without any change. While the third patch did the necessary change to
 make the import file could be built passed in uboot environment.
 
 The fourth patch make us could zip the memory from 0 in the address space.
 
 The latter fifth and sixth patch does the adding gzip lib function
 exporting and zip command support.
 
 Patch set test with zipunzip and compared with original memory content.
 
 
 Lei Wen (6):
   lib: zlib: import deflate source file from 1.2.5
   lib: zlib: import trees file from 1.2.5
   lib: zlib: include deflate into zlib build
   lib: zlib: remove the limitation for cannot using 0 as start
   lib: add gzip lib function callback
   common: add zip command support
 
  common/Makefile   |1 +
  common/cmd_zip.c  |   60 ++
  include/common.h  |7 +
  include/u-boot/zlib.h |   40 +-
  lib/Makefile  |1 +
  lib/gzip.c|  143 
  lib/zlib/deflate.c| 1831
 + lib/zlib/deflate.h| 
 342 +
  lib/zlib/trees.c  | 1244 +
  lib/zlib/trees.h  |  128 
  lib/zlib/zlib.c   |8 +
  lib/zlib/zutil.h  |4 +
  12 files changed, 3804 insertions(+), 5 deletions(-)
  create mode 100644 common/cmd_zip.c
  create mode 100644 lib/gzip.c
  create mode 100644 lib/zlib/deflate.c
  create mode 100644 lib/zlib/deflate.h
  create mode 100644 lib/zlib/trees.c
  create mode 100644 lib/zlib/trees.h

Are there any users for this code? What is it for ?

Best regards,
Marek Vasut
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-09-05 Thread Lei Wen
Hi Marek,

On Thu, Sep 6, 2012 at 12:18 PM, Marek Vasut marek.va...@gmail.com wrote:
 Dear adrian.w...@gmail.com,

 From: Lei Wen lei...@marvell.com

 Lei? Long time no see :)

Long time no see. :)


 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from zlib 1.2.5
 without any change. While the third patch did the necessary change to
 make the import file could be built passed in uboot environment.

 The fourth patch make us could zip the memory from 0 in the address space.

 The latter fifth and sixth patch does the adding gzip lib function
 exporting and zip command support.

 Patch set test with zipunzip and compared with original memory content.


 Lei Wen (6):
   lib: zlib: import deflate source file from 1.2.5
   lib: zlib: import trees file from 1.2.5
   lib: zlib: include deflate into zlib build
   lib: zlib: remove the limitation for cannot using 0 as start
   lib: add gzip lib function callback
   common: add zip command support

  common/Makefile   |1 +
  common/cmd_zip.c  |   60 ++
  include/common.h  |7 +
  include/u-boot/zlib.h |   40 +-
  lib/Makefile  |1 +
  lib/gzip.c|  143 
  lib/zlib/deflate.c| 1831
 + lib/zlib/deflate.h|
 342 +
  lib/zlib/trees.c  | 1244 +
  lib/zlib/trees.h  |  128 
  lib/zlib/zlib.c   |8 +
  lib/zlib/zutil.h  |4 +
  12 files changed, 3804 insertions(+), 5 deletions(-)
  create mode 100644 common/cmd_zip.c
  create mode 100644 lib/gzip.c
  create mode 100644 lib/zlib/deflate.c
  create mode 100644 lib/zlib/deflate.h
  create mode 100644 lib/zlib/trees.c
  create mode 100644 lib/zlib/trees.h

 Are there any users for this code? What is it for ?

This patch was intended to compress the memory when uploading
through USB. So that uploaded image could be smaller.
Maybe there are some other usage, like memory testing?


 Best regards,
 Marek Vasut

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-06-21 Thread Wolfgang Denk
Dear Mike,

In message CALZhoSQpyzWnA=z1am+tuz0ejrhwmug3br90dnfyxjayu6q...@mail.gmail.com 
Lei Wen wrote:
 
  i think you've missed the point of my questions.  we aren't concerned with
  changes you've written (such as patch 4/6 in this series), but bug fixes 
  that
  were added to the zlib code before you updated things.  updating to a newer
  version and dropping previous fixes/optimizations isn't acceptable.

 I didn't overwrite the previous bug fix that existed in the uboot...
 The commit you point out is still there in lib/zlib/inffast.c

 What I am doing is just adding, not subtracting, nor overwriting...
 This patch set change is not to updating the zlib version...
 The previous inflate related stuff in uboot code is kept untouched.

Are you OK with this explanation?

Best regards,

Wolfgang Denk

-- 
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: w...@denx.de
There's a way out of any cage.
-- Captain Christopher Pike, The Menagerie (The Cage),
   stardate unknown.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-05-08 Thread Lei Wen
On Wed, Apr 11, 2012 at 9:24 AM, Lei Wen adrian.w...@gmail.com wrote:
 Hi Mike,

 On Wed, Apr 11, 2012 at 6:11 AM, Mike Frysinger vap...@gentoo.org wrote:
 On Tuesday 10 April 2012 01:05:13 Lei Wen wrote:
 Hi Mike,

 On Tue, Apr 10, 2012 at 12:37 PM, Mike Frysinger vap...@gentoo.org wrote:
  On Tuesday 03 April 2012 05:31:09 Lei Wen wrote:
  Hi Mike,
 
  On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
   On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
   On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
   From: Lei Wen lei...@marvell.com
  
   This patch set add zip command support for uboot.
   The first two patches import deflate and trees functions from zlib
   1.2.5 without any change. While the third patch did the necessary
   change to make the import file could be built passed in uboot
   environment.
  
   Any comments to this series?
  
   did you forward port the misc fixes/optimization that were done ?  or
   did you just drop in the new code ?
 
  The fixes/optimization is already separated in different patch, as the
  0004 in current series.
  Other file is just import as intact from zlib1.2.5, the 0001 and 0002
  patch.
 
  i don't understand what you mean.  0004 is lib: zlib: remove the
  limitation for cannot using 0 as start and doesn't look like a fix that
  was merged before.
 
   for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty
   important
 
  I see. I try my best to keep the current modification history adding
  to the original zlib code.
 
  so you have maintained the bug fixes / optimizations ?  it isn't clear in
  your response (at least to me).

 I see what your concerns...
 Yes, this change is not included in the zlib's own code, but just
 added by myself.
 Without this change, in uboot, we cannot zip from the start of ddr
 memory, since many
 platforms, at least from what I saw, their start ddr memory address is from
 0.

 i think you've missed the point of my questions.  we aren't concerned with
 changes you've written (such as patch 4/6 in this series), but bug fixes that
 were added to the zlib code before you updated things.  updating to a newer
 version and dropping previous fixes/optimizations isn't acceptable.

 I didn't overwrite the previous bug fix that existed in the uboot...
 The commit you point out is still there in lib/zlib/inffast.c

 What I am doing is just adding, not subtracting, nor overwriting...
 This patch set change is not to updating the zlib version...
 The previous inflate related stuff in uboot code is kept untouched.

ping...

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-10 Thread Mike Frysinger
On Tuesday 10 April 2012 01:05:13 Lei Wen wrote:
 Hi Mike,
 
 On Tue, Apr 10, 2012 at 12:37 PM, Mike Frysinger vap...@gentoo.org wrote:
  On Tuesday 03 April 2012 05:31:09 Lei Wen wrote:
  Hi Mike,
  
  On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
   On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
   On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
   From: Lei Wen lei...@marvell.com
   
   This patch set add zip command support for uboot.
   The first two patches import deflate and trees functions from zlib
   1.2.5 without any change. While the third patch did the necessary
   change to make the import file could be built passed in uboot
   environment.
   
   Any comments to this series?
   
   did you forward port the misc fixes/optimization that were done ?  or
   did you just drop in the new code ?
  
  The fixes/optimization is already separated in different patch, as the
  0004 in current series.
  Other file is just import as intact from zlib1.2.5, the 0001 and 0002
  patch.
  
  i don't understand what you mean.  0004 is lib: zlib: remove the
  limitation for cannot using 0 as start and doesn't look like a fix that
  was merged before.
  
   for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty
   important
  
  I see. I try my best to keep the current modification history adding
  to the original zlib code.
  
  so you have maintained the bug fixes / optimizations ?  it isn't clear in
  your response (at least to me).
 
 I see what your concerns...
 Yes, this change is not included in the zlib's own code, but just
 added by myself.
 Without this change, in uboot, we cannot zip from the start of ddr
 memory, since many
 platforms, at least from what I saw, their start ddr memory address is from
 0.

i think you've missed the point of my questions.  we aren't concerned with 
changes you've written (such as patch 4/6 in this series), but bug fixes that 
were added to the zlib code before you updated things.  updating to a newer 
version and dropping previous fixes/optimizations isn't acceptable.
-mike


signature.asc
Description: This is a digitally signed message part.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-10 Thread Lei Wen
Hi Mike,

On Wed, Apr 11, 2012 at 6:11 AM, Mike Frysinger vap...@gentoo.org wrote:
 On Tuesday 10 April 2012 01:05:13 Lei Wen wrote:
 Hi Mike,

 On Tue, Apr 10, 2012 at 12:37 PM, Mike Frysinger vap...@gentoo.org wrote:
  On Tuesday 03 April 2012 05:31:09 Lei Wen wrote:
  Hi Mike,
 
  On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
   On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
   On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
   From: Lei Wen lei...@marvell.com
  
   This patch set add zip command support for uboot.
   The first two patches import deflate and trees functions from zlib
   1.2.5 without any change. While the third patch did the necessary
   change to make the import file could be built passed in uboot
   environment.
  
   Any comments to this series?
  
   did you forward port the misc fixes/optimization that were done ?  or
   did you just drop in the new code ?
 
  The fixes/optimization is already separated in different patch, as the
  0004 in current series.
  Other file is just import as intact from zlib1.2.5, the 0001 and 0002
  patch.
 
  i don't understand what you mean.  0004 is lib: zlib: remove the
  limitation for cannot using 0 as start and doesn't look like a fix that
  was merged before.
 
   for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty
   important
 
  I see. I try my best to keep the current modification history adding
  to the original zlib code.
 
  so you have maintained the bug fixes / optimizations ?  it isn't clear in
  your response (at least to me).

 I see what your concerns...
 Yes, this change is not included in the zlib's own code, but just
 added by myself.
 Without this change, in uboot, we cannot zip from the start of ddr
 memory, since many
 platforms, at least from what I saw, their start ddr memory address is from
 0.

 i think you've missed the point of my questions.  we aren't concerned with
 changes you've written (such as patch 4/6 in this series), but bug fixes that
 were added to the zlib code before you updated things.  updating to a newer
 version and dropping previous fixes/optimizations isn't acceptable.

I didn't overwrite the previous bug fix that existed in the uboot...
The commit you point out is still there in lib/zlib/inffast.c

What I am doing is just adding, not subtracting, nor overwriting...
This patch set change is not to updating the zlib version...
The previous inflate related stuff in uboot code is kept untouched.

 -mike

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-09 Thread Mike Frysinger
On Tuesday 03 April 2012 05:31:09 Lei Wen wrote:
 Hi Mike,
 
 On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
  On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
  On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
  From: Lei Wen lei...@marvell.com
  
  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib
  1.2.5 without any change. While the third patch did the necessary
  change to make the import file could be built passed in uboot
  environment.
  
  Any comments to this series?
  
  did you forward port the misc fixes/optimization that were done ?  or
  did you just drop in the new code ?
 
 The fixes/optimization is already separated in different patch, as the
 0004 in current series.
 Other file is just import as intact from zlib1.2.5, the 0001 and 0002
 patch.

i don't understand what you mean.  0004 is lib: zlib: remove the limitation 
for cannot using 0 as start and doesn't look like a fix that was merged 
before.

  for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty important
 
 I see. I try my best to keep the current modification history adding
 to the original zlib code.

so you have maintained the bug fixes / optimizations ?  it isn't clear in your 
response (at least to me).
-mike


signature.asc
Description: This is a digitally signed message part.
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-09 Thread Lei Wen
Hi Mike,

On Tue, Apr 10, 2012 at 12:37 PM, Mike Frysinger vap...@gentoo.org wrote:
 On Tuesday 03 April 2012 05:31:09 Lei Wen wrote:
 Hi Mike,

 On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
  On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
  On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
  From: Lei Wen lei...@marvell.com
 
  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib
  1.2.5 without any change. While the third patch did the necessary
  change to make the import file could be built passed in uboot
  environment.
 
  Any comments to this series?
 
  did you forward port the misc fixes/optimization that were done ?  or
  did you just drop in the new code ?

 The fixes/optimization is already separated in different patch, as the
 0004 in current series.
 Other file is just import as intact from zlib1.2.5, the 0001 and 0002
 patch.

 i don't understand what you mean.  0004 is lib: zlib: remove the limitation
 for cannot using 0 as start and doesn't look like a fix that was merged
 before.

  for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty important

 I see. I try my best to keep the current modification history adding
 to the original zlib code.

 so you have maintained the bug fixes / optimizations ?  it isn't clear in your
 response (at least to me).

I see what your concerns...
Yes, this change is not included in the zlib's own code, but just
added by myself.
Without this change, in uboot, we cannot zip from the start of ddr
memory, since many
platforms, at least from what I saw, their start ddr memory address is from 0.

If you are still not comfortable with this patch, I could remove the
004 from patch set.
What do you think of this suggestion?

 -mike

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-03 Thread Lei Wen
Hi Mike,

On Tue, Apr 3, 2012 at 3:17 AM, Mike Frysinger vap...@gentoo.org wrote:
 On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
 On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
 From: Lei Wen lei...@marvell.com

 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from zlib 1.2.5
 without any change. While the third patch did the necessary change to
 make the import file could be built passed in uboot environment.

 Any comments to this series?

 did you forward port the misc fixes/optimization that were done ?  or
 did you just drop in the new code ?

The fixes/optimization is already separated in different patch, as the
0004 in current series.
Other file is just import as intact from zlib1.2.5, the 0001 and 0002 patch.



 for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty important

I see. I try my best to keep the current modification history adding
to the original zlib code.


 you can view other fixes by:
  git log -p -- lib_generic/zlib.c
  git log -p -- lib/zlib.c
  git log -p -- lib/zlib/
 -mike

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-02 Thread Lei Wen
Dear Wolfgang,

On Wed, Mar 28, 2012 at 10:23 AM, Lei Wen adrian.w...@gmail.com wrote:
 Hi Tom,

 On Wed, Mar 28, 2012 at 2:12 AM, Tom Rini tr...@ti.com wrote:
 On Tue, Mar 27, 2012 at 04:04:29PM +0800, Lei Wen wrote:
 Hi,

 On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
  From: Lei Wen lei...@marvell.com
 
  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib 1.2.5
  without any change. While the third patch did the necessary change to
  make the import file could be built passed in uboot environment.
 
  The fourth patch make us could zip the memory from 0 in the address space.
 
  The latter fifth and sixth patch does the adding gzip lib function 
  exporting
  and zip command support.
 
  Patch set test with zipunzip and compared with original memory content.
 
 
  Lei Wen (6):
  ?lib: zlib: import deflate source file from 1.2.5
  ?lib: zlib: import trees file from 1.2.5
  ?lib: zlib: include deflate into zlib build
  ?lib: zlib: remove the limitation for cannot using 0 as start
  ?lib: add gzip lib function callback
  ?common: add zip command support
 
  ?common/Makefile ? ? ? | ? ?1 +
  ?common/cmd_zip.c ? ? ?| ? 60 ++
  ?include/common.h ? ? ?| ? ?7 +
  ?include/u-boot/zlib.h | ? 40 +-
  ?lib/Makefile ? ? ? ? ?| ? ?1 +
  ?lib/gzip.c ? ? ? ? ? ?| ?143 
  ?lib/zlib/deflate.c ? ?| 1831 
  +
  ?lib/zlib/deflate.h ? ?| ?342 +
  ?lib/zlib/trees.c ? ? ?| 1244 +
  ?lib/zlib/trees.h ? ? ?| ?128 
  ?lib/zlib/zlib.c ? ? ? | ? ?8 +
  ?lib/zlib/zutil.h ? ? ?| ? ?4 +
  ?12 files changed, 3804 insertions(+), 5 deletions(-)
  ?create mode 100644 common/cmd_zip.c
  ?create mode 100644 lib/gzip.c
  ?create mode 100644 lib/zlib/deflate.c
  ?create mode 100644 lib/zlib/deflate.h
  ?create mode 100644 lib/zlib/trees.c
  ?create mode 100644 lib/zlib/trees.h

 Any comments to this series?

 What's the usecase for this code?  Did the U-Boot change in size for
 targets that didn't opt for the new command?

 There is one usecase in our usage, that is compressing and upload the
 memory content
 through the usb, so that it would reduce the total upload time.
 Certainly, this also could be used to verify current unzip feature
 whether it works well.
 Or some other case, like testing the memory speed?

 No, the new gzip feature only shows up if its configuration is opened,
 or the uboot size would
 not be impacted.

Do you have any comment on this series?

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-04-02 Thread Mike Frysinger
On Tue, Mar 27, 2012 at 04:04, Lei Wen adrian.w...@gmail.com wrote:
 On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
 From: Lei Wen lei...@marvell.com

 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from zlib 1.2.5
 without any change. While the third patch did the necessary change to
 make the import file could be built passed in uboot environment.

 Any comments to this series?

did you forward port the misc fixes/optimization that were done ?  or
did you just drop in the new code ?

for example, cd514aeb996e2f7aefbe1f78481965d9d074aed4 is pretty important

you can view other fixes by:
  git log -p -- lib_generic/zlib.c
  git log -p -- lib/zlib.c
  git log -p -- lib/zlib/
-mike
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-03-27 Thread Lei Wen
Hi,

On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
 From: Lei Wen lei...@marvell.com

 This patch set add zip command support for uboot.
 The first two patches import deflate and trees functions from zlib 1.2.5
 without any change. While the third patch did the necessary change to
 make the import file could be built passed in uboot environment.

 The fourth patch make us could zip the memory from 0 in the address space.

 The latter fifth and sixth patch does the adding gzip lib function exporting
 and zip command support.

 Patch set test with zipunzip and compared with original memory content.


 Lei Wen (6):
  lib: zlib: import deflate source file from 1.2.5
  lib: zlib: import trees file from 1.2.5
  lib: zlib: include deflate into zlib build
  lib: zlib: remove the limitation for cannot using 0 as start
  lib: add gzip lib function callback
  common: add zip command support

  common/Makefile       |    1 +
  common/cmd_zip.c      |   60 ++
  include/common.h      |    7 +
  include/u-boot/zlib.h |   40 +-
  lib/Makefile          |    1 +
  lib/gzip.c            |  143 
  lib/zlib/deflate.c    | 1831 
 +
  lib/zlib/deflate.h    |  342 +
  lib/zlib/trees.c      | 1244 +
  lib/zlib/trees.h      |  128 
  lib/zlib/zlib.c       |    8 +
  lib/zlib/zutil.h      |    4 +
  12 files changed, 3804 insertions(+), 5 deletions(-)
  create mode 100644 common/cmd_zip.c
  create mode 100644 lib/gzip.c
  create mode 100644 lib/zlib/deflate.c
  create mode 100644 lib/zlib/deflate.h
  create mode 100644 lib/zlib/trees.c
  create mode 100644 lib/zlib/trees.h

 --
 1.7.5.4


Any comments to this series?

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-03-27 Thread Tom Rini
On Tue, Mar 27, 2012 at 04:04:29PM +0800, Lei Wen wrote:
 Hi,
 
 On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
  From: Lei Wen lei...@marvell.com
 
  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib 1.2.5
  without any change. While the third patch did the necessary change to
  make the import file could be built passed in uboot environment.
 
  The fourth patch make us could zip the memory from 0 in the address space.
 
  The latter fifth and sixth patch does the adding gzip lib function exporting
  and zip command support.
 
  Patch set test with zipunzip and compared with original memory content.
 
 
  Lei Wen (6):
  ?lib: zlib: import deflate source file from 1.2.5
  ?lib: zlib: import trees file from 1.2.5
  ?lib: zlib: include deflate into zlib build
  ?lib: zlib: remove the limitation for cannot using 0 as start
  ?lib: add gzip lib function callback
  ?common: add zip command support
 
  ?common/Makefile ? ? ? | ? ?1 +
  ?common/cmd_zip.c ? ? ?| ? 60 ++
  ?include/common.h ? ? ?| ? ?7 +
  ?include/u-boot/zlib.h | ? 40 +-
  ?lib/Makefile ? ? ? ? ?| ? ?1 +
  ?lib/gzip.c ? ? ? ? ? ?| ?143 
  ?lib/zlib/deflate.c ? ?| 1831 
  +
  ?lib/zlib/deflate.h ? ?| ?342 +
  ?lib/zlib/trees.c ? ? ?| 1244 +
  ?lib/zlib/trees.h ? ? ?| ?128 
  ?lib/zlib/zlib.c ? ? ? | ? ?8 +
  ?lib/zlib/zutil.h ? ? ?| ? ?4 +
  ?12 files changed, 3804 insertions(+), 5 deletions(-)
  ?create mode 100644 common/cmd_zip.c
  ?create mode 100644 lib/gzip.c
  ?create mode 100644 lib/zlib/deflate.c
  ?create mode 100644 lib/zlib/deflate.h
  ?create mode 100644 lib/zlib/trees.c
  ?create mode 100644 lib/zlib/trees.h
 
 Any comments to this series?

What's the usecase for this code?  Did the U-Boot change in size for
targets that didn't opt for the new command?

-- 
Tom
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH 0/6] add zip command support for uboot

2012-03-27 Thread Lei Wen
Hi Tom,

On Wed, Mar 28, 2012 at 2:12 AM, Tom Rini tr...@ti.com wrote:
 On Tue, Mar 27, 2012 at 04:04:29PM +0800, Lei Wen wrote:
 Hi,

 On Sun, Mar 25, 2012 at 11:53 PM,  adrian.w...@gmail.com wrote:
  From: Lei Wen lei...@marvell.com
 
  This patch set add zip command support for uboot.
  The first two patches import deflate and trees functions from zlib 1.2.5
  without any change. While the third patch did the necessary change to
  make the import file could be built passed in uboot environment.
 
  The fourth patch make us could zip the memory from 0 in the address space.
 
  The latter fifth and sixth patch does the adding gzip lib function 
  exporting
  and zip command support.
 
  Patch set test with zipunzip and compared with original memory content.
 
 
  Lei Wen (6):
  ?lib: zlib: import deflate source file from 1.2.5
  ?lib: zlib: import trees file from 1.2.5
  ?lib: zlib: include deflate into zlib build
  ?lib: zlib: remove the limitation for cannot using 0 as start
  ?lib: add gzip lib function callback
  ?common: add zip command support
 
  ?common/Makefile ? ? ? | ? ?1 +
  ?common/cmd_zip.c ? ? ?| ? 60 ++
  ?include/common.h ? ? ?| ? ?7 +
  ?include/u-boot/zlib.h | ? 40 +-
  ?lib/Makefile ? ? ? ? ?| ? ?1 +
  ?lib/gzip.c ? ? ? ? ? ?| ?143 
  ?lib/zlib/deflate.c ? ?| 1831 
  +
  ?lib/zlib/deflate.h ? ?| ?342 +
  ?lib/zlib/trees.c ? ? ?| 1244 +
  ?lib/zlib/trees.h ? ? ?| ?128 
  ?lib/zlib/zlib.c ? ? ? | ? ?8 +
  ?lib/zlib/zutil.h ? ? ?| ? ?4 +
  ?12 files changed, 3804 insertions(+), 5 deletions(-)
  ?create mode 100644 common/cmd_zip.c
  ?create mode 100644 lib/gzip.c
  ?create mode 100644 lib/zlib/deflate.c
  ?create mode 100644 lib/zlib/deflate.h
  ?create mode 100644 lib/zlib/trees.c
  ?create mode 100644 lib/zlib/trees.h

 Any comments to this series?

 What's the usecase for this code?  Did the U-Boot change in size for
 targets that didn't opt for the new command?

There is one usecase in our usage, that is compressing and upload the
memory content
through the usb, so that it would reduce the total upload time.
Certainly, this also could be used to verify current unzip feature
whether it works well.
Or some other case, like testing the memory speed?

No, the new gzip feature only shows up if its configuration is opened,
or the uboot size would
not be impacted.

 --
 Tom

Thanks,
Lei
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot