summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/board_r.c7
-rw-r--r--common/fdt_support.c12
-rw-r--r--common/image-fdt.c4
3 files changed, 10 insertions, 13 deletions
diff --git a/common/board_r.c b/common/board_r.c
index 19c6427..1b8998d 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -775,7 +775,7 @@ init_fnc_t init_sequence_r[] = {
initr_flash,
#endif
INIT_FUNC_WATCHDOG_RESET
-#if defined(CONFIG_PPC) || defined(CONFIG_X86)
+#if defined(CONFIG_PPC)
/* initialize higher level parts of CPU like time base and timers */
cpu_init_r,
#endif
@@ -838,11 +838,8 @@ init_fnc_t init_sequence_r[] = {
#ifdef CONFIG_CMD_KGDB
initr_kgdb,
#endif
-#ifdef CONFIG_X86
- board_early_init_r,
-#endif
interrupt_init,
-#if defined(CONFIG_ARM) || defined(CONFIG_x86)
+#if defined(CONFIG_ARM)
initr_enable_interrupts,
#endif
#ifdef CONFIG_X86
diff --git a/common/fdt_support.c b/common/fdt_support.c
index 127e17c..8266bca 100644
--- a/common/fdt_support.c
+++ b/common/fdt_support.c
@@ -371,22 +371,22 @@ static int fdt_pack_reg(const void *fdt, void *buf, u64 *address, u64 *size,
int n)
{
int i;
- int address_len = fdt_address_cells(fdt, 0);
- int size_len = fdt_size_cells(fdt, 0);
+ int address_cells = fdt_address_cells(fdt, 0);
+ int size_cells = fdt_size_cells(fdt, 0);
char *p = buf;
for (i = 0; i < n; i++) {
- if (address_len == 2)
+ if (address_cells == 2)
*(fdt64_t *)p = cpu_to_fdt64(address[i]);
else
*(fdt32_t *)p = cpu_to_fdt32(address[i]);
- p += address_len;
+ p += 4 * address_cells;
- if (size_len == 2)
+ if (size_cells == 2)
*(fdt64_t *)p = cpu_to_fdt64(size[i]);
else
*(fdt32_t *)p = cpu_to_fdt32(size[i]);
- p += size_len;
+ p += 4 * size_cells;
}
return p - (char *)buf;
diff --git a/common/image-fdt.c b/common/image-fdt.c
index 1d76bd6..8db3ccb 100644
--- a/common/image-fdt.c
+++ b/common/image-fdt.c
@@ -413,11 +413,11 @@ int boot_get_fdt(int flag, int argc, char * const argv[], uint8_t arch,
}
} else {
debug("## No Flattened Device Tree\n");
- goto error;
+ return 0;
}
} else {
debug("## No Flattened Device Tree\n");
- goto error;
+ return 0;
}
*of_flat_tree = fdt_blob;