diff options
author | Wolfgang Denk <wd@denx.de> | 2011-09-04 22:53:04 +0200 |
---|---|---|
committer | Wolfgang Denk <wd@denx.de> | 2011-09-04 22:53:04 +0200 |
commit | 684cad5717ea5887a09f3c67732a17774a658b34 (patch) | |
tree | b9732b98c6ceba2095e57e0cc2fd002cbb1e026c /arch | |
parent | 6dfbf49c6dc3687efbc6d7f9e25bb46ed2d6c833 (diff) | |
parent | 3f8ce93956fea1fe30db9ea81bc7db1deb401eea (diff) | |
download | u-boot-imx-684cad5717ea5887a09f3c67732a17774a658b34.zip u-boot-imx-684cad5717ea5887a09f3c67732a17774a658b34.tar.gz u-boot-imx-684cad5717ea5887a09f3c67732a17774a658b34.tar.bz2 |
Merge branch 'master' of git://git.denx.de/u-boot-coldfire
* 'master' of git://git.denx.de/u-boot-coldfire:
ColdFire:Clean up the CONFIG_STANDALONE_LOAD_ADDR usage
ColdFire:Add mb for 5253 dram initialization
ColdFire:Define the DM9000 byteswap for M5253 board.
ColdFire:Update the env settings for several boards.
ColdFire:disable the NFS define for 52277 board.
ColdFire:Update the timer_init since it was unified.
ColdFire: Cleanup for partial linking and --gc-sections
ColdFire: Update compile flags for each CPUs
ColdFire:Fix the configuration broken for some boards.
Diffstat (limited to 'arch')
-rw-r--r-- | arch/m68k/config.mk | 5 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf5227x/config.mk | 4 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf523x/config.mk | 4 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf52x2/config.mk | 7 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf532x/config.mk | 6 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf5445x/config.mk | 4 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf547x_8x/config.mk | 4 | ||||
-rw-r--r-- | arch/m68k/cpu/mcf547x_8x/slicetimer.c | 3 | ||||
-rw-r--r-- | arch/m68k/include/asm/io.h | 2 | ||||
-rw-r--r-- | arch/m68k/lib/board.c | 2 | ||||
-rw-r--r-- | arch/m68k/lib/time.c | 6 |
11 files changed, 12 insertions, 35 deletions
diff --git a/arch/m68k/config.mk b/arch/m68k/config.mk index 863f3dd..11ba334 100644 --- a/arch/m68k/config.mk +++ b/arch/m68k/config.mk @@ -23,8 +23,9 @@ CROSS_COMPILE ?= m68k-elf- -clibdir = $(shell dirname `$(CC) $(CFLAGS) -print-file-name=libc.a`) -CONFIG_STANDALONE_LOAD_ADDR ?= 0x20000 -L $(clibdir) +CONFIG_STANDALONE_LOAD_ADDR ?= 0x20000 PLATFORM_CPPFLAGS += -DCONFIG_M68K -D__M68K__ PLATFORM_LDFLAGS += -n +PLATFORM_RELFLAGS += -ffunction-sections -fdata-sections +LDFLAGS_FINAL += --gc-sections diff --git a/arch/m68k/cpu/mcf5227x/config.mk b/arch/m68k/cpu/mcf5227x/config.mk index 8eab49d..f7ee76a 100644 --- a/arch/m68k/cpu/mcf5227x/config.mk +++ b/arch/m68k/cpu/mcf5227x/config.mk @@ -24,8 +24,4 @@ # PLATFORM_RELFLAGS += -ffixed-d7 -msep-data -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) PLATFORM_CPPFLAGS += -mcpu=52277 -fPIC -else -PLATFORM_CPPFLAGS += -m5307 -fPIC -endif diff --git a/arch/m68k/cpu/mcf523x/config.mk b/arch/m68k/cpu/mcf523x/config.mk index fc79454..a5adcee 100644 --- a/arch/m68k/cpu/mcf523x/config.mk +++ b/arch/m68k/cpu/mcf523x/config.mk @@ -24,8 +24,4 @@ # PLATFORM_RELFLAGS += -ffixed-d7 -msep-data -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) PLATFORM_CPPFLAGS += -mcpu=5235 -fPIC -else -PLATFORM_CPPFLAGS += -m5307 -fPIC -endif diff --git a/arch/m68k/cpu/mcf52x2/config.mk b/arch/m68k/cpu/mcf52x2/config.mk index 52751be..22a8462 100644 --- a/arch/m68k/cpu/mcf52x2/config.mk +++ b/arch/m68k/cpu/mcf52x2/config.mk @@ -34,9 +34,6 @@ is5272:=$(shell grep CONFIG_M5272 $(TOPDIR)/include/$(cfg)) is5275:=$(shell grep CONFIG_M5275 $(TOPDIR)/include/$(cfg)) is5282:=$(shell grep CONFIG_M5282 $(TOPDIR)/include/$(cfg)) - -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) - ifneq (,$(findstring CONFIG_M5208,$(is5208))) PLATFORM_CPPFLAGS += -mcpu=5208 endif @@ -58,7 +55,3 @@ endif ifneq (,$(findstring CONFIG_M5282,$(is5282))) PLATFORM_CPPFLAGS += -mcpu=5282 endif - -else -PLATFORM_CPPFLAGS += -m5307 -endif diff --git a/arch/m68k/cpu/mcf532x/config.mk b/arch/m68k/cpu/mcf532x/config.mk index b783444..cd6466a 100644 --- a/arch/m68k/cpu/mcf532x/config.mk +++ b/arch/m68k/cpu/mcf532x/config.mk @@ -29,15 +29,9 @@ cfg=$(shell grep configs $(OBJTREE)/include/config.h | sed 's/.*<\(configs.*\)>/ is5301x:=$(shell grep CONFIG_MCF5301x $(TOPDIR)/include/$(cfg)) is532x:=$(shell grep CONFIG_MCF532x $(TOPDIR)/include/$(cfg)) -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) - ifneq (,$(findstring CONFIG_MCF5301x,$(is5301x))) PLATFORM_CPPFLAGS += -mcpu=53015 -fPIC endif ifneq (,$(findstring CONFIG_MCF532x,$(is532x))) PLATFORM_CPPFLAGS += -mcpu=5329 -fPIC endif - -else -PLATFORM_CPPFLAGS += -m5307 -fPIC -endif diff --git a/arch/m68k/cpu/mcf5445x/config.mk b/arch/m68k/cpu/mcf5445x/config.mk index b0b49f7..61a731e 100644 --- a/arch/m68k/cpu/mcf5445x/config.mk +++ b/arch/m68k/cpu/mcf5445x/config.mk @@ -24,11 +24,7 @@ # PLATFORM_RELFLAGS += -ffixed-d7 -msep-data -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) PLATFORM_CPPFLAGS += -mcpu=54455 -fPIC -else -PLATFORM_CPPFLAGS += -m5407 -fPIC -endif ifneq (,$(findstring -linux-,$(shell $(CC) --version))) ifneq (,$(findstring GOT,$(shell $(LD) --help))) diff --git a/arch/m68k/cpu/mcf547x_8x/config.mk b/arch/m68k/cpu/mcf547x_8x/config.mk index 83102ab..02fce5d 100644 --- a/arch/m68k/cpu/mcf547x_8x/config.mk +++ b/arch/m68k/cpu/mcf547x_8x/config.mk @@ -24,11 +24,7 @@ # PLATFORM_RELFLAGS += -ffixed-d7 -msep-data -ifneq ($(findstring 4.1,$(shell $(CC) --version)),4.1) PLATFORM_CPPFLAGS += -mcpu=5485 -fPIC -else -PLATFORM_CPPFLAGS += -m5407 -fPIC -endif ifneq (,$(findstring -linux-,$(shell $(CC) --version))) ifneq (,$(findstring GOT,$(shell $(LD) --help))) diff --git a/arch/m68k/cpu/mcf547x_8x/slicetimer.c b/arch/m68k/cpu/mcf547x_8x/slicetimer.c index 467a807..ee2e35b 100644 --- a/arch/m68k/cpu/mcf547x_8x/slicetimer.c +++ b/arch/m68k/cpu/mcf547x_8x/slicetimer.c @@ -72,7 +72,7 @@ void dtimer_interrupt(void *not_used) } } -void timer_init(void) +int timer_init(void) { volatile slt_t *timerp = (slt_t *) (CONFIG_SYS_TMR_BASE); @@ -93,6 +93,7 @@ void timer_init(void) /* set a period of 1us, set timer mode to restart and enable timer and interrupt */ timerp->cr = SLT_CR_RUN | SLT_CR_IEN | SLT_CR_TEN; + return 0; } ulong get_timer(ulong base) diff --git a/arch/m68k/include/asm/io.h b/arch/m68k/include/asm/io.h index 531f420..d86eaf9 100644 --- a/arch/m68k/include/asm/io.h +++ b/arch/m68k/include/asm/io.h @@ -81,6 +81,8 @@ #define outl(val, port) out_le32((u32 *)((port)+_IO_BASE), (val)) #endif +#define mb() __asm__ __volatile__ ("" : : : "memory") + extern inline void _insb(volatile u8 * port, void *buf, int ns) { u8 *data = (u8 *) buf; diff --git a/arch/m68k/lib/board.c b/arch/m68k/lib/board.c index 945ab66..1df50f1 100644 --- a/arch/m68k/lib/board.c +++ b/arch/m68k/lib/board.c @@ -78,8 +78,6 @@ static char *failed = "*** failed ***\n"; extern ulong __init_end; extern ulong __bss_end__; -extern void timer_init(void); - #if defined(CONFIG_WATCHDOG) # define INIT_FUNC_WATCHDOG_INIT watchdog_init, # define WATCHDOG_DISABLE watchdog_disable diff --git a/arch/m68k/lib/time.c b/arch/m68k/lib/time.c index a316cdf..a0e2441 100644 --- a/arch/m68k/lib/time.c +++ b/arch/m68k/lib/time.c @@ -91,7 +91,7 @@ void dtimer_interrupt(void *not_used) } } -void timer_init(void) +int timer_init(void) { volatile dtmr_t *timerp = (dtmr_t *) (CONFIG_SYS_TMR_BASE); @@ -114,6 +114,8 @@ void timer_init(void) /* set a period of 1us, set timer mode to restart and enable timer and interrupt */ timerp->tmr = CONFIG_SYS_TIMER_PRESCALER | DTIM_DTMR_CLK_DIV1 | DTIM_DTMR_FRR | DTIM_DTMR_ORRI | DTIM_DTMR_RST_EN; + + return 0; } ulong get_timer(ulong base) @@ -162,6 +164,8 @@ void timer_init(void) timerp->pcsr = PIT_PCSR_OVW; timerp->pmr = lastinc = 0; timerp->pcsr |= PIT_PCSR_PRE(CONFIG_SYS_PIT_PRESCALE) | PIT_PCSR_EN; + + return 0; } ulong get_timer(ulong base) |