This is the mail archive of the ecos-devel@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RedBoot: Auto-detection of gzipped/non-gzipped images


Hi folks,

This suggestion is meant for RedBoot's flash.c:

In our product, we are soon running out of flash space, which has forced us
to start using gzipped images. This means that we've enabled the
CYGPRI_REDBOOT_ZLIB_FLASH and started using the "-d" option in the boot
script for unpacking the images:
   fis load -d my_image

This works fine.

However, we need to be backwards compatible, so that old, non-gzipped images
can be loaded without passing it through the uncompressor. Loading such an
image would require a script change so that the "-d" option was ommited:
  fis load my_image

In order to avoid this script change, I've added an auto-detect mechanism,
where - when enabled - the image will first be passed through the
uncompressor, and only if that one fails, it is one-to-one copied from Flash
to RAM. In this way, both types of images will be able to load correctly
using:
  fis load -a my_image

I've attached a patch. Please have a look and let me know what you think.
http://www.nabble.com/file/p13967870/diff.patch diff.patch 
Thx.
Renà Schipp von Branitz Nielsen
Vitesse Semiconductors

-- 
View this message in context: http://www.nabble.com/RedBoot%3A-Auto-detection-of-gzipped-non-gzipped-images-tf4880764.html#a13967870
Sent from the Sourceware - ecos-devel mailing list archive at Nabble.com.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]