Decompression code

Sturniolo Jose jsturnio at nec.com.ar
Mon Apr 9 19:16:44 UTC 2001


Ilya,
	Here I'm including a zip file with the files changed to get a
"COMPRESSED" image file.
I'll try to explain how it works, in order to clarify the code:

LINKCMDS:
Basic regions map.
ROM image  mapping:
 .textrom
	First configuration code (BSP, start) and decompresor (@miscgz.o)
	Compresed File containing .text, .data, generated by apl / Makefile
using gzip.
.text
	All the uncompresed code.
	Contains all the code EXCEPT : start.o, init68360.o and @miscgz.o (I
tried to use the EXCEPT keyword at link time, but I got it working when I
was finished with it)

.data
	All the uncompresed data

.datarom
	Data segment used to hold variables used by the decompresor.


The basic idea is:
The loader code must to be set into  in the .textrom and .datarom segment,
by mean of keywords like :
void _Init68360 (void) __attribute__((section(".textrom"))); 

You can avoid to used these keywords if you use the EXCEPT keyword in the
linker, but this keyword must be used with a entire object file.

Main changes related to original file:
start.S	=> section is .textrom now. ClearBSSandStart function was added.
init68360 => section is .textrom now. After the first settings, the
decompresion function is called (decompress_kernel() )
@miscgz => new file, contains the decompresion code.
apl / Makefile  => you can use this example makefile to build the compressed
image, it use the gettdb.pl file.

Regards.	



 <<tests.zip>> 

Jose Sturniolo

-------------- next part --------------
A non-text attachment was scrubbed...
Name: tests.zip
Type: application/octet-stream
Size: 35487 bytes
Desc: not available
URL: <http://lists.rtems.org/pipermail/users/attachments/20010409/0fc9a3a5/attachment.obj>


More information about the users mailing list