exynos5420: Make USB A-A booting work with early data cache
Apparently the IROM doesn't like data caches... the recently added dcache-in-bootblock makes A-A booting fail, and flushes/invalidations alone don't seem to fix it. It's pretty fast anyway, so we just disable the cache again for the duration of the IROM call. Also removes a superfluous invalidation line from the bootblock code... dcache_mmu_enable/disable already take care of that. BUG=chrome-os-partner:18733 TEST=cros_write_firmware -i <coreboot image> -b peach_pit (with CL:65276) Change-Id: I35580d15664c7b4197d4ed14028720147adbf918 Signed-off-by: Julius Werner <jwerner@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/66602 Reviewed-by: Gabe Black <gabeblack@chromium.org> Reviewed-by: David Hendricks <dhendrix@chromium.org>
This commit is contained in:
parent
c072543946
commit
e9c28a6a7a
2 changed files with 4 additions and 1 deletions
|
|
@ -22,6 +22,7 @@
|
|||
#include <cbfs.h> /* This driver serves as a CBFS media source. */
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <arch/cache.h>
|
||||
#include <console/console.h>
|
||||
#include "alternate_cbfs.h"
|
||||
#include "spi.h"
|
||||
|
|
@ -52,10 +53,13 @@ static int usb_cbfs_open(struct cbfs_media *media)
|
|||
if (!first_run)
|
||||
return 0;
|
||||
|
||||
dcache_mmu_disable();
|
||||
if (!irom_load_usb()) {
|
||||
dcache_mmu_enable();
|
||||
printk(BIOS_ERR, "Unable to load CBFS image via USB!\n");
|
||||
return -1;
|
||||
}
|
||||
dcache_mmu_enable();
|
||||
|
||||
/*
|
||||
* We need to trust the host/irom to copy the image to our
|
||||
|
|
|
|||
|
|
@ -63,7 +63,6 @@ void bootblock_cpu_init(void)
|
|||
mmu_config_range(0, SRAM_START, DCACHE_OFF);
|
||||
mmu_config_range(SRAM_START, SRAM_SIZE, DCACHE_WRITEBACK);
|
||||
mmu_config_range(SRAM_END, 4096 - SRAM_END, DCACHE_OFF);
|
||||
dcache_invalidate_all();
|
||||
dcache_mmu_enable();
|
||||
|
||||
/* For most ARM systems, we have to initialize firmware media source
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue