public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] no flush_cache() call at the end of do_fat_fsload?
@ 2009-01-29 14:47 Scott Coulter
  2009-01-29 15:44 ` Stefan Roese
  0 siblings, 1 reply; 2+ messages in thread
From: Scott Coulter @ 2009-01-29 14:47 UTC (permalink / raw)
  To: u-boot


Hi all,

Maybe a stupid question, but does anyone no why there is no call to
flush_cache() at the end of do_fat_fsload()?  I haven't tried it on the
latest u-boot, but I had an issue the other day where I was trying to
load a VxWorks image from a Compact Flash card on a MPC8572-based board.
The same image booted fine with tftpboot, but when I loaded the image
off of the CF card using the fatload command, the image didn't boot.  I
confirmed that image was copied faithfully into DRAM.  I then noticed
that the tftpload command (netboot_common) has a call to flush_cache()
after the download to memory completes, so I added the following to the
end of do_fat_fsload():

	...

	/* flush cache */
	flush_cache(offset, size);

	return 0;
}

Then the image booted...


Thanks,
Scott




___________________________________________________________________

  Scott N. Coulter
  Senior Software Engineer
  
  Cyclone Microsystems          
  370 James Street              Phone:  203.786.5536 ext. 118
  New Haven, CT 06513-3051      Email:  scott.coulter at cyclone.com
  U.S.A.                        Web:    http://www.cyclone.com
___________________________________________________________________

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

* [U-Boot] no flush_cache() call at the end of do_fat_fsload?
  2009-01-29 14:47 [U-Boot] no flush_cache() call at the end of do_fat_fsload? Scott Coulter
@ 2009-01-29 15:44 ` Stefan Roese
  0 siblings, 0 replies; 2+ messages in thread
From: Stefan Roese @ 2009-01-29 15:44 UTC (permalink / raw)
  To: u-boot

Hi Scott,

On Thursday 29 January 2009, Scott Coulter wrote:
> Maybe a stupid question, but does anyone no why there is no call to
> flush_cache() at the end of do_fat_fsload()?

A bug perhaps?

> I haven't tried it on the 
> latest u-boot, but I had an issue the other day where I was trying to
> load a VxWorks image from a Compact Flash card on a MPC8572-based board.
> The same image booted fine with tftpboot, but when I loaded the image
> off of the CF card using the fatload command, the image didn't boot.  I
> confirmed that image was copied faithfully into DRAM.  I then noticed
> that the tftpload command (netboot_common) has a call to flush_cache()
> after the download to memory completes, so I added the following to the
> end of do_fat_fsload():
>
> 	...
>
> 	/* flush cache */
> 	flush_cache(offset, size);
>
> 	return 0;
> }
>
> Then the image booted...

Makes perfect sense. Best would be if you could send a proper patch to fix 
this.

Thanks.

Best regards,
Stefan

=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: office at denx.de
=====================================================================

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

end of thread, other threads:[~2009-01-29 15:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-29 14:47 [U-Boot] no flush_cache() call at the end of do_fat_fsload? Scott Coulter
2009-01-29 15:44 ` Stefan Roese

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