Replace CONFIG_RELOC_FIXUP_WORKS by CONFIG_NEEDS_MANUAL_RELOC
By now, the majority of architectures have working relocation
support, so the few remaining architectures have become exceptions.
To make this more obvious, we make working relocation now the default
case, and flag the remaining cases with CONFIG_NEEDS_MANUAL_RELOC.
Signed-off-by: Wolfgang Denk <wd@denx.de>
Tested-by: Heiko Schocher <hs@denx.de>
Tested-by: Reinhard Meyer <u-boot@emk-elektronik.de>
diff --git a/arch/arm/include/asm/config.h b/arch/arm/include/asm/config.h
index 4124f0a..c60dba2 100644
--- a/arch/arm/include/asm/config.h
+++ b/arch/arm/include/asm/config.h
@@ -21,9 +21,6 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
-/* Relocation to SDRAM works on all ARM boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
#define CONFIG_LMB
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
#endif
diff --git a/arch/arm/lib/board.c b/arch/arm/lib/board.c
index af9a414..33b3694 100644
--- a/arch/arm/lib/board.c
+++ b/arch/arm/lib/board.c
@@ -679,15 +679,6 @@
#if !defined(CONFIG_SYS_NO_FLASH)
ulong flash_size;
#endif
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
- extern void malloc_bin_reloc (void);
-#if defined(CONFIG_CMD_BMP)
- extern void bmp_reloc(void);
-#endif
-#if defined(CONFIG_CMD_I2C)
- extern void i2c_reloc(void);
-#endif
-#endif
gd = id;
bd = gd->bd;
@@ -704,39 +695,16 @@
debug ("Now running in RAM - U-Boot at: %08lx\n", dest_addr);
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
- /*
- * We have to relocate the command table manually
- */
- fixup_cmdtable(&__u_boot_cmd_start,
- (ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
-#if defined(CONFIG_CMD_BMP)
- bmp_reloc();
-#endif
-#if defined(CONFIG_CMD_I2C)
- i2c_reloc();
-#endif
-#if defined(CONFIG_CMD_ONENAND)
- onenand_reloc();
-#endif
-#endif /* !defined(CONFIG_RELOC_FIXUP_WORKS) */
-
#ifdef CONFIG_LOGBUFFER
logbuff_init_ptrs ();
#endif
#ifdef CONFIG_POST
post_output_backlog ();
-#ifndef CONFIG_RELOC_FIXUP_WORKS
- post_reloc ();
-#endif
#endif
/* The Malloc area is immediately below the monitor copy in DRAM */
malloc_start = dest_addr - TOTAL_MALLOC_LEN;
mem_malloc_init (malloc_start, TOTAL_MALLOC_LEN);
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
- malloc_bin_reloc ();
-#endif
#if !defined(CONFIG_SYS_NO_FLASH)
puts ("FLASH: ");
diff --git a/arch/avr32/include/asm/config.h b/arch/avr32/include/asm/config.h
index 049c44e..02fbfb3 100644
--- a/arch/avr32/include/asm/config.h
+++ b/arch/avr32/include/asm/config.h
@@ -21,4 +21,6 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
+#define CONFIG_NEEDS_MANUAL_RELOC
+
#endif
diff --git a/arch/avr32/lib/board.c b/arch/avr32/lib/board.c
index 96ccc7f..8b56237 100644
--- a/arch/avr32/lib/board.c
+++ b/arch/avr32/lib/board.c
@@ -272,13 +272,13 @@
monitor_flash_len = _edata - _text;
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/*
* We have to relocate the command table manually
*/
fixup_cmdtable(&__u_boot_cmd_start,
(ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
-#endif /* !defined(CONFIG_RELOC_FIXUP_WORKS) */
+#endif /* defined(CONFIG_NEEDS_MANUAL_RELOC) */
/* there are some other pointer constants we must deal with */
#ifndef CONFIG_ENV_IS_NOWHERE
diff --git a/arch/blackfin/include/asm/config.h b/arch/blackfin/include/asm/config.h
index 34ca68c..388434f 100644
--- a/arch/blackfin/include/asm/config.h
+++ b/arch/blackfin/include/asm/config.h
@@ -13,9 +13,6 @@
# define CONFIG_BFIN_SCRATCH_REG retn
#endif
-/* Relocation to SDRAM works on all Blackfin boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
/* Make sure the structure is properly aligned */
#if ((CONFIG_SYS_GBL_DATA_ADDR & -4) != CONFIG_SYS_GBL_DATA_ADDR)
# error CONFIG_SYS_GBL_DATA_ADDR: must be 4 byte aligned
diff --git a/arch/i386/include/asm/config.h b/arch/i386/include/asm/config.h
index 1952de7..049c44e 100644
--- a/arch/i386/include/asm/config.h
+++ b/arch/i386/include/asm/config.h
@@ -21,6 +21,4 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
-#define CONFIG_RELOC_FIXUP_WORKS
-
#endif
diff --git a/arch/m68k/include/asm/config.h b/arch/m68k/include/asm/config.h
index ec2cc16..51050a3 100644
--- a/arch/m68k/include/asm/config.h
+++ b/arch/m68k/include/asm/config.h
@@ -21,6 +21,8 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
+#define CONFIG_NEEDS_MANUAL_RELOC
+
#define CONFIG_LMB
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
#define CONFIG_SYS_BOOT_GET_CMDLINE
diff --git a/arch/m68k/lib/board.c b/arch/m68k/lib/board.c
index 976d5bf..9a51908 100644
--- a/arch/m68k/lib/board.c
+++ b/arch/m68k/lib/board.c
@@ -420,13 +420,13 @@
monitor_flash_len = (ulong)&__init_end - dest_addr;
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/*
* We have to relocate the command table manually
*/
fixup_cmdtable(&__u_boot_cmd_start,
(ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
-#endif /* !defined(CONFIG_RELOC_FIXUP_WORKS) */
+#endif /* defined(CONFIG_NEEDS_MANUAL_RELOC) */
/* there are some other pointer constants we must deal with */
#ifndef CONFIG_ENV_IS_NOWHERE
diff --git a/arch/microblaze/include/asm/config.h b/arch/microblaze/include/asm/config.h
index 8a9064b..049c44e 100644
--- a/arch/microblaze/include/asm/config.h
+++ b/arch/microblaze/include/asm/config.h
@@ -21,7 +21,4 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
-/* Relocation to SDRAM works on all Microblaze boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
#endif
diff --git a/arch/mips/include/asm/config.h b/arch/mips/include/asm/config.h
index 049c44e..02fbfb3 100644
--- a/arch/mips/include/asm/config.h
+++ b/arch/mips/include/asm/config.h
@@ -21,4 +21,6 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
+#define CONFIG_NEEDS_MANUAL_RELOC
+
#endif
diff --git a/arch/mips/lib/board.c b/arch/mips/lib/board.c
index 4a22f7b..f317124 100644
--- a/arch/mips/lib/board.c
+++ b/arch/mips/lib/board.c
@@ -295,13 +295,13 @@
monitor_flash_len = (ulong)&uboot_end_data - dest_addr;
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/*
* We have to relocate the command table manually
*/
fixup_cmdtable(&__u_boot_cmd_start,
(ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
-#endif /* !defined(CONFIG_RELOC_FIXUP_WORKS) */
+#endif /* defined(CONFIG_NEEDS_MANUAL_RELOC) */
/* there are some other pointer constants we must deal with */
#ifndef CONFIG_ENV_IS_NOWHERE
diff --git a/arch/nios2/include/asm/config.h b/arch/nios2/include/asm/config.h
index 011d603..049c44e 100644
--- a/arch/nios2/include/asm/config.h
+++ b/arch/nios2/include/asm/config.h
@@ -21,7 +21,4 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
-/* Relocation to SDRAM works on all NIOS2 boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
#endif
diff --git a/arch/powerpc/include/asm/config.h b/arch/powerpc/include/asm/config.h
index a1942ca..76dedeb 100644
--- a/arch/powerpc/include/asm/config.h
+++ b/arch/powerpc/include/asm/config.h
@@ -89,9 +89,6 @@
#define CONFIG_SYS_NUM_TLBCAMS 16
#endif
-/* Relocation to SDRAM works on all PPC boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
/* Since so many PPC SOCs have a semi-common LBC, define this here */
#if defined(CONFIG_MPC85xx) || defined(CONFIG_MPC86xx) || \
defined(CONFIG_MPC83xx)
diff --git a/arch/sh/include/asm/config.h b/arch/sh/include/asm/config.h
index 978cc92..049c44e 100644
--- a/arch/sh/include/asm/config.h
+++ b/arch/sh/include/asm/config.h
@@ -21,7 +21,4 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
-/* Relocation to SDRAM works on all sh boards */
-#define CONFIG_RELOC_FIXUP_WORKS
-
#endif
diff --git a/arch/sparc/include/asm/config.h b/arch/sparc/include/asm/config.h
index 6ddc349..7b6f30b 100644
--- a/arch/sparc/include/asm/config.h
+++ b/arch/sparc/include/asm/config.h
@@ -21,6 +21,8 @@
#ifndef _ASM_CONFIG_H_
#define _ASM_CONFIG_H_
+#define CONFIG_NEEDS_MANUAL_RELOC
+
#define CONFIG_LMB
#define CONFIG_SYS_BOOT_RAMDISK_HIGH
diff --git a/arch/sparc/lib/board.c b/arch/sparc/lib/board.c
index 4a6041f..ab31cfb 100644
--- a/arch/sparc/lib/board.c
+++ b/arch/sparc/lib/board.c
@@ -252,13 +252,13 @@
post_run(NULL, POST_ROM | post_bootmode_get(0));
#endif
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/*
* We have to relocate the command table manually
*/
fixup_cmdtable(&__u_boot_cmd_start,
(ulong)(&__u_boot_cmd_end - &__u_boot_cmd_start));
-#endif /* !defined(CONFIG_RELOC_FIXUP_WORKS) */
+#endif /* defined(CONFIG_NEEDS_MANUAL_RELOC) */
#if defined(CONFIG_CMD_AMBAPP) && defined(CONFIG_SYS_AMBAPP_PRINT_ON_STARTUP)
puts("AMBA:\n");
diff --git a/common/cmd_bmp.c b/common/cmd_bmp.c
index 6fa8a15..f2a48f7 100644
--- a/common/cmd_bmp.c
+++ b/common/cmd_bmp.c
@@ -137,7 +137,7 @@
U_BOOT_CMD_MKENT(display, 5, 0, do_bmp_display, "", ""),
};
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void bmp_reloc(void) {
fixup_cmdtable(cmd_bmp_sub, ARRAY_SIZE(cmd_bmp_sub));
}
diff --git a/common/cmd_bootm.c b/common/cmd_bootm.c
index ce3c77c..1a024f1 100644
--- a/common/cmd_bootm.c
+++ b/common/cmd_bootm.c
@@ -590,7 +590,7 @@
ulong load_end = 0;
int ret;
boot_os_fn *boot_fn;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
static int relocated = 0;
/* relocate boot function table */
diff --git a/common/cmd_date.c b/common/cmd_date.c
index 50b4240..8dbf16d 100644
--- a/common/cmd_date.c
+++ b/common/cmd_date.c
@@ -35,10 +35,10 @@
"Sun", "Mon", "Tues", "Wednes", "Thurs", "Fri", "Satur",
};
-#ifdef CONFIG_RELOC_FIXUP_WORKS
-#define RELOC(a) a
-#else
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
#define RELOC(a) ((typeof(a))((unsigned long)(a) + gd->reloc_off))
+#else
+#define RELOC(a) a
#endif
int mk_date (char *, struct rtc_time *);
diff --git a/common/cmd_i2c.c b/common/cmd_i2c.c
index 0a0cfce..c272b0d 100644
--- a/common/cmd_i2c.c
+++ b/common/cmd_i2c.c
@@ -1284,7 +1284,7 @@
U_BOOT_CMD_MKENT(speed, 1, 1, do_i2c_bus_speed, "", ""),
};
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void i2c_reloc(void) {
fixup_cmdtable(cmd_i2c_sub, ARRAY_SIZE(cmd_i2c_sub));
}
diff --git a/common/cmd_nvedit.c b/common/cmd_nvedit.c
index 3d30c32..3fd8abc 100644
--- a/common/cmd_nvedit.c
+++ b/common/cmd_nvedit.c
@@ -837,7 +837,7 @@
U_BOOT_CMD_MKENT(set, CONFIG_SYS_MAXARGS, 0, do_env_set, "", ""),
};
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
void env_reloc(void)
{
fixup_cmdtable(cmd_env_sub, ARRAY_SIZE(cmd_env_sub));
diff --git a/common/cmd_onenand.c b/common/cmd_onenand.c
index 5550b40..33108f1 100644
--- a/common/cmd_onenand.c
+++ b/common/cmd_onenand.c
@@ -525,7 +525,7 @@
U_BOOT_CMD_MKENT(markbad, CONFIG_SYS_MAXARGS, 0, do_onenand_markbad, "", ""),
};
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void onenand_reloc(void) {
fixup_cmdtable(cmd_onenand_sub, ARRAY_SIZE(cmd_onenand_sub));
}
diff --git a/common/command.c b/common/command.c
index d47d719..0020eac 100644
--- a/common/command.c
+++ b/common/command.c
@@ -466,7 +466,7 @@
}
#endif
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
DECLARE_GLOBAL_DATA_PTR;
void fixup_cmdtable(cmd_tbl_t *cmdtp, int size)
diff --git a/common/dlmalloc.c b/common/dlmalloc.c
index fce7a76..4871f4b 100644
--- a/common/dlmalloc.c
+++ b/common/dlmalloc.c
@@ -1491,7 +1491,7 @@
IAV(120), IAV(121), IAV(122), IAV(123), IAV(124), IAV(125), IAV(126), IAV(127)
};
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void malloc_bin_reloc (void)
{
unsigned long *p = (unsigned long *)(&av_[2]);
diff --git a/common/env_common.c b/common/env_common.c
index 5acda4d..a276efc 100644
--- a/common/env_common.c
+++ b/common/env_common.c
@@ -227,7 +227,7 @@
void env_relocate (void)
{
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
extern void env_reloc(void);
env_reloc();
diff --git a/common/hush.c b/common/hush.c
index 4dd9513..2188fd4 100644
--- a/common/hush.c
+++ b/common/hush.c
@@ -3268,7 +3268,7 @@
}
#ifdef __U_BOOT__
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
static void u_boot_hush_reloc(void)
{
unsigned long addr;
@@ -3290,7 +3290,7 @@
top_vars->next = 0;
top_vars->flg_export = 0;
top_vars->flg_read_only = 1;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
u_boot_hush_reloc();
#endif
}
diff --git a/common/image.c b/common/image.c
index 89c10b8..42f5b79 100644
--- a/common/image.c
+++ b/common/image.c
@@ -520,7 +520,7 @@
{
for (; table->id >= 0; ++table) {
if (table->id == id)
-#if defined(USE_HOSTCC) || defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(USE_HOSTCC) || !defined(CONFIG_NEEDS_MANUAL_RELOC)
return table->lname;
#else
return table->lname + gd->reloc_off;
@@ -585,10 +585,10 @@
fprintf (stderr, "\n");
#else
for (t = table; t->id >= 0; ++t) {
-#ifdef CONFIG_RELOC_FIXUP_WORKS
- if (t->sname && strcmp(t->sname, name) == 0)
-#else
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
if (t->sname && strcmp(t->sname + gd->reloc_off, name) == 0)
+#else
+ if (t->sname && strcmp(t->sname, name) == 0)
#endif
return (t->id);
}
diff --git a/common/serial.c b/common/serial.c
index c3323ea..051ae4e 100644
--- a/common/serial.c
+++ b/common/serial.c
@@ -99,7 +99,7 @@
int serial_register (struct serial_device *dev)
{
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
dev->init += gd->reloc_off;
dev->setbrg += gd->reloc_off;
dev->getc += gd->reloc_off;
diff --git a/common/stdio.c b/common/stdio.c
index 2501369..ab7c5ab 100644
--- a/common/stdio.c
+++ b/common/stdio.c
@@ -193,7 +193,7 @@
int stdio_init (void)
{
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/* already relocated for current ARM implementation */
ulong relocation_offset = gd->reloc_off;
int i;
@@ -203,7 +203,7 @@
stdio_names[i] = (char *) (((ulong) stdio_names[i]) +
relocation_offset);
}
-#endif /* !CONFIG_RELOC_FIXUP_WORKS */
+#endif /* CONFIG_NEEDS_MANUAL_RELOC */
/* Initialize the list */
INIT_LIST_HEAD(&(devs.list));
diff --git a/disk/part.c b/disk/part.c
index 2b63db6..13723f2 100644
--- a/disk/part.c
+++ b/disk/part.c
@@ -81,13 +81,13 @@
char *name;
name = drvr->name;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
name += gd->reloc_off;
#endif
while (name) {
name = drvr->name;
reloc_get_dev = drvr->get_dev;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
name += gd->reloc_off;
reloc_get_dev += gd->reloc_off;
#endif
diff --git a/doc/README.arm-relocation b/doc/README.arm-relocation
index dc7be7e..2f91d0a 100644
--- a/doc/README.arm-relocation
+++ b/doc/README.arm-relocation
@@ -36,15 +36,14 @@
At config level:
- Define CONFIG_RELOC_FIXUP_WORKS.
Undefine CONFIG_SYS_ARM_WITHOUT_RELOC
* WARNING ** WARNING ** WARNING ** WARNING ** WARNING ** WARNING ** WARNING *
Boards which are not fixed to support relocation will be REMOVED!
-Eventually, CONFIG_SYS_ARM_WITHOUT_RELOC and CONFIG_RELOC_FIXUP_WORKS will
-disappear and boards which have to migrated to relocation will disappear too.
+Eventually, CONFIG_SYS_ARM_WITHOUT_RELOC will disappear and boards
+which have to migrated to relocation will disappear too.
-----------------------------------------------------------------------------
diff --git a/drivers/mtd/nand/nand.c b/drivers/mtd/nand/nand.c
index 47d6872..c0e068a 100644
--- a/drivers/mtd/nand/nand.c
+++ b/drivers/mtd/nand/nand.c
@@ -54,7 +54,7 @@
if (nand_scan(mtd, maxchips) == 0) {
if (!mtd->name)
mtd->name = (char *)default_nand_name;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
else
mtd->name += gd->reloc_off;
#endif
diff --git a/drivers/net/phy/miiphybb.c b/drivers/net/phy/miiphybb.c
index 1045cf1..49a1f5f 100644
--- a/drivers/net/phy/miiphybb.c
+++ b/drivers/net/phy/miiphybb.c
@@ -127,7 +127,7 @@
int i;
for (i = 0; i < bb_miiphy_buses_num; i++) {
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
/* Relocate the hook pointers*/
BB_MII_RELOCATE(bb_miiphy_buses[i].init, gd->reloc_off);
BB_MII_RELOCATE(bb_miiphy_buses[i].mdio_active, gd->reloc_off);
diff --git a/fs/ubifs/ubifs.c b/fs/ubifs/ubifs.c
index 3fc7990..1cc31a9 100644
--- a/fs/ubifs/ubifs.c
+++ b/fs/ubifs/ubifs.c
@@ -121,7 +121,7 @@
{
ubifs_compressors[compr->compr_type] = compr;
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
ubifs_compressors[compr->compr_type]->name += gd->reloc_off;
ubifs_compressors[compr->compr_type]->capi_name += gd->reloc_off;
ubifs_compressors[compr->compr_type]->decompress += gd->reloc_off;
diff --git a/include/command.h b/include/command.h
index 5c14616..46a9ec4 100644
--- a/include/command.h
+++ b/include/command.h
@@ -125,7 +125,7 @@
#endif /* CONFIG_SYS_LONGHELP */
-#if !defined(CONFIG_RELOC_FIXUP_WORKS)
+#if defined(CONFIG_NEEDS_MANUAL_RELOC)
void fixup_cmdtable(cmd_tbl_t *cmdtp, int size);
#endif
#endif /* __COMMAND_H */
diff --git a/include/post.h b/include/post.h
index abe47da..957ce3b 100644
--- a/include/post.h
+++ b/include/post.h
@@ -137,7 +137,7 @@
int post_run (char *name, int flags);
int post_info (char *name);
int post_log (char *format, ...);
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void post_reloc (void);
#endif
unsigned long post_time_ms (unsigned long base);
diff --git a/post/post.c b/post/post.c
index 8a9fd0d..1b7f2aa 100644
--- a/post/post.c
+++ b/post/post.c
@@ -422,7 +422,7 @@
return 0;
}
-#ifndef CONFIG_RELOC_FIXUP_WORKS
+#ifdef CONFIG_NEEDS_MANUAL_RELOC
void post_reloc (void)
{
unsigned int i;