public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] armv7m: Disable D-cache when booting nommu(ARMv7M) Linux kernel
@ 2017-06-04 16:18 Toshifumi NISHINAGA
  2017-06-10 13:46 ` [U-Boot] " Tom Rini
  0 siblings, 1 reply; 2+ messages in thread
From: Toshifumi NISHINAGA @ 2017-06-04 16:18 UTC (permalink / raw)
  To: u-boot

Disable D-Cache is required when booting nommu Linux kernel.
(please see Linux kernel source "arch/arm/kernel/head-nommu.S")

U-Boot is enabled D-cache and I-Cache at startup.
However, it does not disable D-Cache before
booting nommu Linux kernel.
Therefore, I call dcache_disable()
when the CPU is ARMv7M to fix this problem.

Signed-off-by: Toshifumi NISHINAGA <tnishinaga.dev@gmail.com>
---
 arch/arm/lib/bootm.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/lib/bootm.c b/arch/arm/lib/bootm.c
index 4dbe6a5303..d14a8b5737 100644
--- a/arch/arm/lib/bootm.c
+++ b/arch/arm/lib/bootm.c
@@ -359,6 +359,7 @@ static void boot_jump_linux(bootm_headers_t *images, int flag)
 #ifdef CONFIG_CPU_V7M
 	ulong addr = (ulong)kernel_entry | 1;
 	kernel_entry = (void *)addr;
+	dcache_disable();
 #endif
 	s = getenv("machid");
 	if (s) {
-- 
2.13.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [U-Boot] armv7m: Disable D-cache when booting nommu(ARMv7M) Linux kernel
  2017-06-04 16:18 [U-Boot] [PATCH] armv7m: Disable D-cache when booting nommu(ARMv7M) Linux kernel Toshifumi NISHINAGA
@ 2017-06-10 13:46 ` Tom Rini
  0 siblings, 0 replies; 2+ messages in thread
From: Tom Rini @ 2017-06-10 13:46 UTC (permalink / raw)
  To: u-boot

On Mon, Jun 05, 2017 at 01:18:08AM +0900, tnishinaga.dev at gmail.com wrote:

> Disable D-Cache is required when booting nommu Linux kernel.
> (please see Linux kernel source "arch/arm/kernel/head-nommu.S")
> 
> U-Boot is enabled D-cache and I-Cache at startup.
> However, it does not disable D-Cache before
> booting nommu Linux kernel.
> Therefore, I call dcache_disable()
> when the CPU is ARMv7M to fix this problem.
> 
> Signed-off-by: Toshifumi NISHINAGA <tnishinaga.dev@gmail.com>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20170610/f3e952bf/attachment.sig>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-06-10 13:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-04 16:18 [U-Boot] [PATCH] armv7m: Disable D-cache when booting nommu(ARMv7M) Linux kernel Toshifumi NISHINAGA
2017-06-10 13:46 ` [U-Boot] " Tom Rini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox