summaryrefslogtreecommitdiff
path: root/lib_ppc
diff options
context:
space:
mode:
Diffstat (limited to 'lib_ppc')
-rw-r--r--lib_ppc/bat_rw.c6
-rw-r--r--lib_ppc/bootm.c5
-rw-r--r--lib_ppc/time.c4
3 files changed, 9 insertions, 6 deletions
diff --git a/lib_ppc/bat_rw.c b/lib_ppc/bat_rw.c
index 8546333868d..a40b377bcaa 100644
--- a/lib_ppc/bat_rw.c
+++ b/lib_ppc/bat_rw.c
@@ -25,9 +25,12 @@
#include <common.h>
#include <asm/processor.h>
#include <asm/mmu.h>
+#include <asm/io.h>
int write_bat (ppc_bat_t bat, unsigned long upper, unsigned long lower)
{
+ sync();
+
switch (bat) {
case DBAT0:
mtspr (DBAT0L, lower);
@@ -99,6 +102,9 @@ int write_bat (ppc_bat_t bat, unsigned long upper, unsigned long lower)
return (-1);
}
+ sync();
+ isync();
+
return (0);
}
diff --git a/lib_ppc/bootm.c b/lib_ppc/bootm.c
index 81803ddef3d..cbe5592a948 100644
--- a/lib_ppc/bootm.c
+++ b/lib_ppc/bootm.c
@@ -277,8 +277,6 @@ do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
#if defined(CFG_INIT_RAM_LOCK) && !defined(CONFIG_E500)
unlock_ram_in_cache();
#endif
- if (!images->autostart)
- return ;
#if defined(CONFIG_OF_LIBFDT)
if (of_flat_tree) { /* device tree; boot new style */
@@ -311,8 +309,7 @@ do_bootm_linux(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[],
return ;
error:
- if (images->autostart)
- do_reset (cmdtp, flag, argc, argv);
+ do_reset (cmdtp, flag, argc, argv);
return ;
}
diff --git a/lib_ppc/time.c b/lib_ppc/time.c
index 2649d5ffdca..f093a578543 100644
--- a/lib_ppc/time.c
+++ b/lib_ppc/time.c
@@ -67,7 +67,7 @@ void udelay(unsigned long usec)
}
/* ------------------------------------------------------------------------- */
-
+#ifndef CONFIG_NAND_SPL
unsigned long ticks2usec(unsigned long ticks)
{
ulong tbclk = get_tbclk();
@@ -83,7 +83,7 @@ unsigned long ticks2usec(unsigned long ticks)
return ((ulong)ticks);
}
-
+#endif
/* ------------------------------------------------------------------------- */
int init_timebase (void)