* [U-Boot-Users] do_bootm() and flush_cache()
@ 2005-03-23 1:40 Scott McNutt
2005-03-23 19:21 ` Wolfgang Denk
0 siblings, 1 reply; 3+ messages in thread
From: Scott McNutt @ 2005-03-23 1:40 UTC (permalink / raw)
To: u-boot
I'm looking for some guidance:
On some processors (e.g. Nios-II), the instruction and
data caches can't be disabled. The code for loadb, loads,
etc. call flush_cache() ... so life is good.
But after reviewing do_bootm(), I don't see where the
caches are flushed. A call to flush_cache() after
moving/decompressing the image seems appropriate, but
I'm not sure if this would break other architectures ...
... do I need to wrap an ifdef around a call to
flush_cache() ?
Regards,
--Scott
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot-Users] do_bootm() and flush_cache()
2005-03-23 1:40 [U-Boot-Users] do_bootm() and flush_cache() Scott McNutt
@ 2005-03-23 19:21 ` Wolfgang Denk
2005-03-24 2:56 ` Scott McNutt
0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Denk @ 2005-03-23 19:21 UTC (permalink / raw)
To: u-boot
In message <4240C916.30901@psyent.com> you wrote:
>
> But after reviewing do_bootm(), I don't see where the
> caches are flushed. A call to flush_cache() after
> moving/decompressing the image seems appropriate, but
Why?
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"Open the pod bay doors, HAL." - Dave Bowman, 2001
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot-Users] do_bootm() and flush_cache()
2005-03-23 19:21 ` Wolfgang Denk
@ 2005-03-24 2:56 ` Scott McNutt
0 siblings, 0 replies; 3+ messages in thread
From: Scott McNutt @ 2005-03-24 2:56 UTC (permalink / raw)
To: u-boot
>>But after reviewing do_bootm(), I don't see where the
>>caches are flushed. A call to flush_cache() after
>>moving/decompressing the image seems appropriate, but
>
>
> Why?
After the move/decompression, the data cache must be
flushed to main memory ... otherwise an instruction
cache miss (after jumping into the kernel) may read
in a (potentially) stale line. (Neither cache can be
disabled.)
Regards,
--Scott
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2005-03-24 2:56 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-23 1:40 [U-Boot-Users] do_bootm() and flush_cache() Scott McNutt
2005-03-23 19:21 ` Wolfgang Denk
2005-03-24 2:56 ` Scott McNutt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox