bootstage: Correct relocation algorithm
[oweals/u-boot.git] / common / board_f.c
index 591f18f391e22e7ae515c265de050e63f5d7e156..e3591cbaebdbf48aa9fd65ddafdd26c1a167b530 100644 (file)
@@ -588,6 +588,7 @@ static int reserve_stacks(void)
 static int reserve_bloblist(void)
 {
 #ifdef CONFIG_BLOBLIST
+       gd->start_addr_sp &= ~0xf;
        gd->start_addr_sp -= CONFIG_BLOBLIST_SIZE;
        gd->new_bloblist = map_sysmem(gd->start_addr_sp, CONFIG_BLOBLIST_SIZE);
 #endif
@@ -695,6 +696,7 @@ static int reloc_bootstage(void)
                      gd->bootstage, gd->new_bootstage, size);
                memcpy(gd->new_bootstage, gd->bootstage, size);
                gd->bootstage = gd->new_bootstage;
+               bootstage_relocate();
        }
 #endif