fatfs v0.12c March 04, 2017:

- Improved write throughput at the fragmented file on the exFAT volume.
- Made memory usage for exFAT be able to be reduced as decreasing _MAX_LFN.
- Fixed successive f_getfree() can return wrong count on the FAT12/16 volume. (appeared at R0.12)
- Fixed configuration option _VOLUMES cannot be set 10. (appeared at R0.10c)
This commit is contained in:
savelij13 committed 2025-09-11 10:24:04 +03:00
1 parent e749807f86
commit fca959be37
63 files changed
+620 -499

No files matched your search

+4 -4
View File
@@ -13,7 +13,7 @@
<div class="para func">
<h2>disk_read</h2>
<p>The disk_read function reads sector(s) from the storage device.</p>
<p>The disk_read function is called to read data from the sector(s) of storage device.</p>
<pre>
DRESULT disk_read (
BYTE <span class="arg">pdrv</span>, <span class="c">/* [IN] Physical drive number */</span>
@@ -45,7 +45,7 @@ DRESULT disk_read (
<dt>RES_OK (0)</dt>
<dd>The function succeeded.</dd>
<dt>RES_ERROR</dt>
<dd>Any hard error occured during the read operation and could not recover it.</dd>
<dd>A hard error occured during the read operation and could not recover it.</dd>
<dt>RES_PARERR</dt>
<dd>Invalid parameter.</dd>
<dt>RES_NOTRDY</dt>
@@ -60,8 +60,8 @@ DRESULT disk_read (
<p>The memory address specified by <tt class="arg">buff</tt> is not that always aligned to word boundary because the argument is defined as <tt>BYTE*</tt>. The unaligned read/write request can occure at <a href="appnote.html#fs1">direct transfer</a>. If the bus architecture, especially DMA controller, does not allow unaligned memory access, it should be solved in this function. There are some workarounds described below to avoid this issue.</p>
<ul>
<li>Convert word transfer to byte transfer in this function if needed. - Recommended.</li>
<li>On the <tt>f_read</tt> calls, avoid long read request that includes a whole of sector. - Any direct transfer never occures.</li>
<li>On the <tt>f_read</tt> calls, make sure that <tt>(((UINT)data &amp; 3) == (f_tell(fp) &amp; 3))</tt> is true. - Word alignment of <tt>buff</tt> is guaranteed.</li>
<li>On the <tt>f_read()</tt> calls, avoid long read request that includes a whole of sector. - Any direct transfer never occures.</li>
<li>On the <tt>f_read(fp, data, btw, bw)</tt> calls, make sure that <tt>(((UINT)data &amp; 3) == (f_tell(fp) &amp; 3))</tt> is true. - Word alignment of <tt class="arg">buff</tt> is guaranteed.</li>
</ul>
<p>Generally, a multiple sector transfer request must not be split into single sector transactions to the storage device, or you will not get good read throughput.</p>
</div>