ports/sysutils/u-boot-rpi/files/patch-common_cmd__boot.c
Brad Davis b16e31e0a9 Update sysutils/u-boot-rpi to 2015.10
Submitted by:	ian
Approved by:	bdrewery (mentor)
2015-10-23 19:12:27 +00:00

18 lines
663 B
C

--- common/cmd_boot.c.orig 2015-10-19 23:59:38 UTC
+++ common/cmd_boot.c
@@ -19,6 +19,15 @@ __attribute__((weak))
unsigned long do_go_exec(ulong (*entry)(int, char * const []), int argc,
char * const argv[])
{
+ /*
+ * FreeBSD wants the caches enabled while ubldr runs, and as of r276397
+ * the kernel can tolerate being entered with internal (but not external
+ * PL310) caches enabled on armv6/7 systems. So don't disable caches
+ * here, just invalidate the icache (because we DMA'd new data into that
+ * memory recently) and launch the program directly.
+ */
+ flush_dcache_all();
+ invalidate_icache_all();
return entry (argc, argv);
}