From 8371dc2066136be21e10b7b9293e469297d77298 Mon Sep 17 00:00:00 2001 From: TsiChung Liew Date: Wed, 18 Jun 2008 19:05:23 -0500 Subject: ColdFire: Add -got=single param for new linux v4e toolchains Signed-off-by: Kurt Mahan --- cpu/mcf5445x/config.mk | 6 ++++++ cpu/mcf547x_8x/config.mk | 6 ++++++ 2 files changed, 12 insertions(+) (limited to 'cpu') diff --git a/cpu/mcf5445x/config.mk b/cpu/mcf5445x/config.mk index 88433f2f6d6..67efa07af75 100644 --- a/cpu/mcf5445x/config.mk +++ b/cpu/mcf5445x/config.mk @@ -29,3 +29,9 @@ PLATFORM_CPPFLAGS += -mcpu=54455 -fPIC else PLATFORM_CPPFLAGS += -m5407 -fPIC endif + +ifneq (,$(findstring -linux-,$(shell $(CC) --version))) +ifneq (,$(findstring GOT,$(shell $(LD) --help))) +PLATFORM_LDFLAGS += --got=single +endif +endif diff --git a/cpu/mcf547x_8x/config.mk b/cpu/mcf547x_8x/config.mk index e5f4385dd35..567b2819264 100644 --- a/cpu/mcf547x_8x/config.mk +++ b/cpu/mcf547x_8x/config.mk @@ -29,3 +29,9 @@ PLATFORM_CPPFLAGS += -mcpu=5485 -fPIC else PLATFORM_CPPFLAGS += -m5407 -fPIC endif + +ifneq (,$(findstring -linux-,$(shell $(CC) --version))) +ifneq (,$(findstring GOT,$(shell $(LD) --help))) +PLATFORM_LDFLAGS += --got=single +endif +endif -- cgit v1.2.3 From 3b1e8ac9b43f89cc9291a6a86e6b33ef55801515 Mon Sep 17 00:00:00 2001 From: TsiChung Liew Date: Wed, 18 Jun 2008 19:12:13 -0500 Subject: ColdFire: Change invalid JMP to BRA caught by new v4e toolchain Signed-off-by: Kurt Mahan --- cpu/mcf5445x/start.S | 2 +- cpu/mcf547x_8x/start.S | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'cpu') diff --git a/cpu/mcf5445x/start.S b/cpu/mcf5445x/start.S index 3241b278e1c..89ec7bcc914 100644 --- a/cpu/mcf5445x/start.S +++ b/cpu/mcf5445x/start.S @@ -253,7 +253,7 @@ clear_bss: /* exception code */ .globl _fault _fault: - jmp _fault + bra _fault .globl _exc_handler _exc_handler: diff --git a/cpu/mcf547x_8x/start.S b/cpu/mcf547x_8x/start.S index 8b8708d030b..87355f95813 100644 --- a/cpu/mcf547x_8x/start.S +++ b/cpu/mcf547x_8x/start.S @@ -259,7 +259,7 @@ clear_bss: /* exception code */ .globl _fault _fault: - jmp _fault + bra _fault .globl _exc_handler _exc_handler: -- cgit v1.2.3 From dd08e97361fbc9e79fa5ef1a8acf29273b934b11 Mon Sep 17 00:00:00 2001 From: TsiChung Liew Date: Wed, 18 Jun 2008 19:19:07 -0500 Subject: ColdFire: Fix compiling error for MCF5275 The compiling error was caused by missing a closed parentheses in speed.c Signed-off-by: TsiChung Liew --- cpu/mcf52x2/speed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cpu') diff --git a/cpu/mcf52x2/speed.c b/cpu/mcf52x2/speed.c index 5fafcd8c5f9..f6edd5b6fa8 100644 --- a/cpu/mcf52x2/speed.c +++ b/cpu/mcf52x2/speed.c @@ -69,7 +69,7 @@ int get_clocks (void) /* Setup PLL */ pll->syncr = 0x01080000; - while (!(pll->synsr & FMPLL_SYNSR_LOCK) + while (!(pll->synsr & FMPLL_SYNSR_LOCK)) ; pll->syncr = 0x01000000; while (!(pll->synsr & FMPLL_SYNSR_LOCK)) -- cgit v1.2.3 From bc3ccb139f0836f0a834cfd370a120a00ad7e63a Mon Sep 17 00:00:00 2001 From: TsiChung Liew Date: Wed, 9 Jul 2008 15:47:27 -0500 Subject: ColdFire: Fix incorrect define for mcf5227x and mcf5445x RTC Rename CONFIG_MCFTMR to CONFIG_MCFRTC to include real time clock module in cpu//cpu_init.c Signed-off-by: TsiChung Liew --- cpu/mcf5227x/cpu_init.c | 2 +- cpu/mcf5445x/cpu_init.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'cpu') diff --git a/cpu/mcf5227x/cpu_init.c b/cpu/mcf5227x/cpu_init.c index 71b053d4d6e..cf29559e714 100644 --- a/cpu/mcf5227x/cpu_init.c +++ b/cpu/mcf5227x/cpu_init.c @@ -106,7 +106,7 @@ void cpu_init_f(void) */ int cpu_init_r(void) { -#ifdef CONFIG_MCFTMR +#ifdef CONFIG_MCFRTC volatile rtc_t *rtc = (volatile rtc_t *)(CFG_MCFRTC_BASE); volatile rtcex_t *rtcex = (volatile rtcex_t *)&rtc->extended; u32 oscillator = CFG_RTC_OSCILLATOR; diff --git a/cpu/mcf5445x/cpu_init.c b/cpu/mcf5445x/cpu_init.c index 585216d6e6f..e07748bd802 100644 --- a/cpu/mcf5445x/cpu_init.c +++ b/cpu/mcf5445x/cpu_init.c @@ -110,7 +110,7 @@ void cpu_init_f(void) */ int cpu_init_r(void) { -#ifdef CONFIG_MCFTMR +#ifdef CONFIG_MCFRTC volatile rtc_t *rtc = (volatile rtc_t *)(CFG_MCFRTC_BASE); volatile rtcex_t *rtcex = (volatile rtcex_t *)&rtc->extended; -- cgit v1.2.3 From 47bf9c71ae838305a3ea3161af8d14e6f3fc2c82 Mon Sep 17 00:00:00 2001 From: TsiChung Liew Date: Wed, 9 Jul 2008 16:20:23 -0500 Subject: ColdFire: Fix FB CS not setup properly for Mcf5282 Remove all CFG_CSn_RO in cpu/mcf52x2/cpu_init.c. If CFG_CSn_RO is defined as 0, the chipselect will not be assigned. Signed-off-by: TsiChung Liew --- cpu/mcf52x2/cpu_init.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'cpu') diff --git a/cpu/mcf52x2/cpu_init.c b/cpu/mcf52x2/cpu_init.c index 207a37e7d57..344bceeda10 100644 --- a/cpu/mcf52x2/cpu_init.c +++ b/cpu/mcf52x2/cpu_init.c @@ -419,8 +419,7 @@ void cpu_init_f(void) else is doing it! */ #if defined(CFG_CS0_BASE) & defined(CFG_CS0_SIZE) & \ - defined(CFG_CS0_WIDTH) & defined(CFG_CS0_RO) & \ - defined(CFG_CS0_WS) + defined(CFG_CS0_WIDTH) & defined(CFG_CS0_WS) MCFCSM_CSAR0 = (CFG_CS0_BASE >> 16) & 0xFFFF; @@ -447,8 +446,7 @@ void cpu_init_f(void) #endif #if defined(CFG_CS1_BASE) & defined(CFG_CS1_SIZE) & \ - defined(CFG_CS1_WIDTH) & defined(CFG_CS1_RO) & \ - defined(CFG_CS1_WS) + defined(CFG_CS1_WIDTH) & defined(CFG_CS1_WS) MCFCSM_CSAR1 = (CFG_CS1_BASE >> 16) & 0xFFFF; @@ -476,8 +474,7 @@ void cpu_init_f(void) #endif #if defined(CFG_CS2_BASE) & defined(CFG_CS2_SIZE) & \ - defined(CFG_CS2_WIDTH) & defined(CFG_CS2_RO) & \ - defined(CFG_CS2_WS) + defined(CFG_CS2_WIDTH) & defined(CFG_CS2_WS) MCFCSM_CSAR2 = (CFG_CS2_BASE >> 16) & 0xFFFF; @@ -505,8 +502,7 @@ void cpu_init_f(void) #endif #if defined(CFG_CS3_BASE) & defined(CFG_CS3_SIZE) & \ - defined(CFG_CS3_WIDTH) & defined(CFG_CS3_RO) & \ - defined(CFG_CS3_WS) + defined(CFG_CS3_WIDTH) & defined(CFG_CS3_WS) MCFCSM_CSAR3 = (CFG_CS3_BASE >> 16) & 0xFFFF; -- cgit v1.2.3