U-Boot timeout on sata load but no error detected

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

U-Boot timeout on sata load but no error detected

438 Views
dirkweber
Contributor I

Hi,

I am facing a strange problem when loading a small file (less thaqn 512 bytes) from a SATA disk using U-Boot:

The transfer times out but the load will succeed eventually. The same problem happens when loading files of any size that have the last block non-contiguous.

When stepping through the U-Boot sources that behavior is easy to explain:

The FAT FS will first load any number of blocks of a cluster (including no blocks!) and than load the last 512 bytes for the remaining data. The fsl_sata.c does not care about sata_read() with blkcnt==0 and will therefor timeout (the disk will not send a complete when there is no data to transfer).

While this problem is easy to fix I wonder why this issue I haven't been reported anywhere yet...

...or is there any mistake on my side??

Cheers,

Dirk

Labels (1)
0 Kudos
1 Reply

342 Views
yipingwang
NXP TechSupport
NXP TechSupport

Hello Dirk Weber ,

Previously other customers reported similar issue like this.

In U-Boot file /fs/fat/fat.c, function get_contents() line 365, we think that this original fat.c code can not support under 4096 byte. It's needed to modify the line 359~363 and 390 as support under 4096 byte.


Have a great day,
TIC

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos