[lkml]   [2006]   [Feb]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 0/7] inflate pt1: refactor boot-time inflate code
On Fri, 24 Feb 2006, Matt Mackall wrote:

> This is a refactored version of the lib/inflate.c:
> - clean up some really ugly code
> - clean up atrocities like '#include "../../../lib/inflate.c"'
> - drop a ton of cut and paste code from the kernel boot
> - move towards making the boot decompressor pluggable
> - move towards unifying the multiple inflate implementations
> - save space

Could you also make sure that there is no non-const global variables
whatsoever in there? The idea is that on ARM the decompressor was once
made to be executable directly from flash so the deflated kernel image
would be stored at its final location in ram directly without first
copying zImage nor any .data to ram in order to execute it. This is a
significant boot time saving (which I think CE Linux is interested in)
while still preserving a compressed kernel in flash.


$ size lib/zlib_inflate/zlib_inflate.o
text data bss dec hex filename
11868 68 0 11936 2ea0 lib/zlib_inflate/zlib_inflate.o

Since this code is probably reentrant already, global variables are most
probably read-only and declaring them const will store their content
into .rodata which should be accounted as text above.

Having an empty .data section is the easiest way to be sure the kernel
decompressor can actually execute from flash without subtle bugs due to
the enforced read-only nature of global variables.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-02-24 23:09    [W:0.048 / U:0.528 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site