Skip to content

Commit

Permalink
ARM: 5985/2: ARM: Fix Samsung build after "ARM: Eliminate decompresso…
Browse files Browse the repository at this point in the history
…r -Dstatic= PIC hack"

Commit 5de813b (ARM: Eliminate decompressor -Dstatic= PIC hack) among
other things changed the declared type of the error() function to an
extern, conflicting with the forward declartion in the Samsung
plat/uncompress.h which appears to have been relying on the static
being defined away, causing build failures since error() ends up with
a GOT relocation but the linker script discards all GOT relocated
data and functions:

arch/arm/boot/compressed/decompress.o: In function `gunzip':
/home/broonie/git/linux-2.6/arch/arm/boot/compressed/../../../../lib/decompress_
+inflate.c:68: undefined reference to `error'

and so on. Fix this by moving the declaration into uncompress/misc.c
where it is shared with the rest of the code, correcting the definition
as we go.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Mark Brown authored and Russell King committed Mar 13, 2010
1 parent daf9fe2 commit a2302b4
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 1 addition & 0 deletions arch/arm/boot/compressed/misc.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ unsigned int __machine_arch_type;
#else

static void putstr(const char *ptr);
extern void error(char *x);

#include <mach/uncompress.h>

Expand Down
2 changes: 0 additions & 2 deletions arch/arm/plat-samsung/include/plat/uncompress.h
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,6 @@ static void arch_decomp_error(const char *x)
#define arch_error arch_decomp_error
#endif

static void error(char *err);

#ifdef CONFIG_S3C_BOOT_UART_FORCE_FIFO
static inline void arch_enable_uart_fifo(void)
{
Expand Down

0 comments on commit a2302b4

Please sign in to comment.