diff options
author | Graeme Russ <graeme.russ@gmail.com> | 2011-02-12 15:12:01 +1100 |
---|---|---|
committer | Graeme Russ <graeme.russ@gmail.com> | 2011-02-12 15:12:01 +1100 |
commit | bf6af154a48a19d29c17cd35dd78a61bc045026f (patch) | |
tree | da7c3eff78d561838e86a61d2727b38952604a37 /arch/i386/cpu/sc520/sc520.c | |
parent | c869e2ac46a7a8ca00d1fd24c6399ca8e256e244 (diff) | |
download | u-boot-imx-bf6af154a48a19d29c17cd35dd78a61bc045026f.zip u-boot-imx-bf6af154a48a19d29c17cd35dd78a61bc045026f.tar.gz u-boot-imx-bf6af154a48a19d29c17cd35dd78a61bc045026f.tar.bz2 |
x86: Move test for cold boot into init functions
Diffstat (limited to 'arch/i386/cpu/sc520/sc520.c')
-rw-r--r-- | arch/i386/cpu/sc520/sc520.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/i386/cpu/sc520/sc520.c b/arch/i386/cpu/sc520/sc520.c index d5597ca..e5dcac6 100644 --- a/arch/i386/cpu/sc520/sc520.c +++ b/arch/i386/cpu/sc520/sc520.c @@ -45,15 +45,16 @@ int cpu_init_f(void) gd->cpu_clk = 100000000; } - /* wait at least one millisecond */ asm("movl $0x2000, %%ecx\n" "0: pushl %%ecx\n" "popl %%ecx\n" "loop 0b\n": : : "ecx"); - /* turn on the SDRAM write buffer */ - writeb(0x11, &sc520_mmcr->dbctl); + if (gd->flags & GD_FLG_COLD_BOOT) { + /* turn on the SDRAM write buffer */ + writeb(0x11, &sc520_mmcr->dbctl); + } return x86_cpu_init_f(); } |