[PATCH 3/3] ARM: zImage: fix issues with missing GOT entries for some global variables
nicolas.pitre at linaro.org
Wed Apr 20 09:17:04 EDT 2011
On Wed, 20 Apr 2011, Nicolas Pitre wrote:
> On Wed, 20 Apr 2011, Shawn Guo wrote:
> > Though I'm unsure if it realistically exists, what if it's a static
> > variable inside a function? It's actually changing something, right?
> Right. In that case the variable is allocated to the .data section, but
> we explicitly discard .data at link time to prevent a successful build.
Sorry, more clarification is needed here.
The patch changing all occurrences of "static" into nothing would break
code using static variables within functions. I just hope that no one
is using local static variables in their uncompress.h file.
And local static variables are always using GOTOFF relocations which is
what we want to avoid in the first place.
The conclusion is that no one should be using local static variables in
code linked by the kernel decompressor, unless those variables are also
More information about the linux-arm-kernel