Skip to content
Commit 5de813b6 authored by Russell King's avatar Russell King
Browse files

ARM: Eliminate decompressor -Dstatic= PIC hack



We used to build decompressors with -Dstatic= to avoid any local data
being generated.  The problem is that local data generates GOTOFF
relocations, which means we can't relocate the data relative to the
text segment.

Global data, on the other hand, goes through the GOT, and can be
relocated anywhere.

Unfortunately, with the new decompressors, this presents a problem
since they declare static data within functions, and this leads to
stack overflow.

Fix this by separating out the decompressor code into a separate file,
and removing 'static' from BSS data in misc.c.

Also, discard the .data section - this means that should we end up
with read/write initialized data, the decompressor will fail to link
and the problem will be obvious.

Acked-by: default avatarNicolas Pitre <nico@fluxnic.net>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent d6d502fa
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment