This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: FATFS Problems to read the partition table on compact flash >128MB


Per Hedblom wrote:

Hi,

My fatfs could not create windows compatible fat files on my 256Mb compact
flash card. The disk works fine within eCos but the files newer shows up on
my windows machine. A 128 mb card works fine. I traced down the problem to
how the partition table is read. The current implementation uses the two
C/H/S fields to find the start and end of each disk partition (offset 1 and
5).


My 256Mb compact flash works if I change the code to read the absolute start
position and size fields (offset 8 and 12). Se patch below.

I don't know how read the partition table in a correct way so it would be
nice If someone could suggest a more generally applicable code change.


Several people had problems with CHS partition info before... and using LBA (like you do)
solved the problem. The question is how to choose which entry to use - CHS or LBA.
Maybe the best way is to always use the LBA entry - is there any format tool which doesn't
set the LBA correctly ?


How are the CHS fields set on your 256Mb CF ?

savin


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]