1
0
mirror of https://xff.cz/git/u-boot/ synced 2025-09-01 08:42:12 +02:00

powerpc/bootm: Flush ramdisk and device tree image when booting on MP

We already flush the kernel image after we've loaded it to ensure
visiblity to the other cores.  We need to do the same thing for the
ramdisk and device tree images.  In AMP boot scenarios we might not be
HW cache coherent with the secondary core that we are loading and
setting the ramdisk and device tree up for.  Thus we need to ensure
we've flushed the regions of memory utilized by ramdisk and device tree
so the loadding and any modifications (from decompression or fdt updates)
are made visible to the secondary cores.

Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
This commit is contained in:
Kumar Gala
2011-12-07 04:42:58 +00:00
committed by Wolfgang Denk
parent 02ab0970b3
commit 3b2001105f
2 changed files with 24 additions and 6 deletions

View File

@@ -1104,6 +1104,14 @@ int boot_ramdisk_high(struct lmb *lmb, ulong rd_data, ulong rd_len,
memmove_wd((void *)*initrd_start,
(void *)rd_data, rd_len, CHUNKSZ);
#ifdef CONFIG_MP
/*
* Ensure the image is flushed to memory to handle
* AMP boot scenarios in which we might not be
* HW cache coherent
*/
flush_cache((unsigned long)*initrd_start, rd_len);
#endif
puts("OK\n");
}
} else {