From 521af04d853361b49344b61892eb0618f9f713c5 Mon Sep 17 00:00:00 2001 From: Peter Tyser Date: Mon, 21 Sep 2009 11:20:36 -0500 Subject: Conditionally perform common relocation fixups Add #ifdefs where necessary to not perform relocation fixups. This allows boards/architectures which support relocation to trim a decent chunk of code. Note that this patch doesn't add #ifdefs to architecture-specific code which does not support relocation. Signed-off-by: Peter Tyser --- common/cmd_date.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'common/cmd_date.c') diff --git a/common/cmd_date.c b/common/cmd_date.c index b69e935085..9f50f8956e 100644 --- a/common/cmd_date.c +++ b/common/cmd_date.c @@ -35,7 +35,11 @@ const char *weekdays[] = { "Sun", "Mon", "Tues", "Wednes", "Thurs", "Fri", "Satur", }; +#ifdef CONFIG_RELOC_FIXUP_WORKS +#define RELOC(a) a +#else #define RELOC(a) ((typeof(a))((unsigned long)(a) + gd->reloc_off)) +#endif int mk_date (char *, struct rtc_time *); -- cgit v1.2.1