All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter.
@ 2011-11-18 19:06 Reinhard Arlt
  2011-11-18 19:58 ` Mike Frysinger
  2012-03-18 19:14 ` Wolfgang Denk
  0 siblings, 2 replies; 3+ messages in thread
From: Reinhard Arlt @ 2011-11-18 19:06 UTC (permalink / raw)
  To: u-boot

From: Reinhard Arlt <reinhard.arlt@esd.eu>

This patch clear and disable the data cache for vxWorks.

The entry point sysInit(int) intended by Windriver to be called from
the vxWorks bootrom, a very small vxWorks system.
The routine is called by the go() handler in the bootrom, that clears
the cache from start of image to end of usable memory.

The PowerPC implementations only invalidates and disable the cache,
the ARM implementations also flush it.
  
U-Boot will be on the save side, if it disables the data cache before
calling vxWorks sysInit(int).

Signed-off-by: Reinhard Arlt <reinhard.arlt@esd.eu>

--

diff --git a/common/cmd_elf.c b/common/cmd_elf.c
index 11ffc1b..8266bba 100644
--- a/common/cmd_elf.c
+++ b/common/cmd_elf.c
@@ -230,7 +230,8 @@ int do_bootvx (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 			(char *) bootaddr);
 	printf ("## Starting vxWorks at 0x%08lx ...\n", addr);
 
-	((void (*)(void)) addr) ();
+	dcache_disable();
+	((void (*)(int)) addr) (0);
 
 	puts ("## vxWorks terminated\n");
 	return 1;

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

* [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter.
  2011-11-18 19:06 [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter Reinhard Arlt
@ 2011-11-18 19:58 ` Mike Frysinger
  2012-03-18 19:14 ` Wolfgang Denk
  1 sibling, 0 replies; 3+ messages in thread
From: Mike Frysinger @ 2011-11-18 19:58 UTC (permalink / raw)
  To: u-boot

On Friday 18 November 2011 14:06:52 Reinhard Arlt wrote:
> U-Boot will be on the save side, if it disables the data cache before

s/save/safe/
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20111118/5c92c127/attachment.pgp>

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

* [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter.
  2011-11-18 19:06 [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter Reinhard Arlt
  2011-11-18 19:58 ` Mike Frysinger
@ 2012-03-18 19:14 ` Wolfgang Denk
  1 sibling, 0 replies; 3+ messages in thread
From: Wolfgang Denk @ 2012-03-18 19:14 UTC (permalink / raw)
  To: u-boot

Dear Reinhard Arlt,

In message <4EC6ACCC.5070709@esd.eu> you wrote:
> From: Reinhard Arlt <reinhard.arlt@esd.eu>
> 
> This patch clear and disable the data cache for vxWorks.
> 
> The entry point sysInit(int) intended by Windriver to be called from
> the vxWorks bootrom, a very small vxWorks system.
> The routine is called by the go() handler in the bootrom, that clears
> the cache from start of image to end of usable memory.
> 
> The PowerPC implementations only invalidates and disable the cache,
> the ARM implementations also flush it.
>   
> U-Boot will be on the save side, if it disables the data cache before
> calling vxWorks sysInit(int).
> 
> Signed-off-by: Reinhard Arlt <reinhard.arlt@esd.eu>

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
 The software required `Windows 95 or better', so I installed Linux.

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

end of thread, other threads:[~2012-03-18 19:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-18 19:06 [U-Boot] [PATCH v2] bootvx: Clear and disable data cache, and call vxWorks with parameter Reinhard Arlt
2011-11-18 19:58 ` Mike Frysinger
2012-03-18 19:14 ` Wolfgang Denk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.