summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2003-10-22 16:31:17 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2003-10-22 16:31:17 +0000
commit897fe13f8c9bcca1e38fdb15e8b4bca086b45550 (patch)
treef44bfd78e9adc88b575baac443618236f453ca7d /cpukit
parent2003-10-22 Joel Sherrill <joel@OARcorp.com> (diff)
downloadrtems-897fe13f8c9bcca1e38fdb15e8b4bca086b45550.tar.bz2
2003-10-22 Joel Sherrill <joel@OARcorp.com>
PR 440/filesystem * src/dosfs/fat_fat_operations.c: Improve write speed with FAT12 and FAT16 filesystems. Previously merged on 4.6 branch.
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/libfs/ChangeLog6
-rw-r--r--cpukit/libfs/src/dosfs/fat_fat_operations.c30
2 files changed, 19 insertions, 17 deletions
diff --git a/cpukit/libfs/ChangeLog b/cpukit/libfs/ChangeLog
index 753ea1ad76..07923ec407 100644
--- a/cpukit/libfs/ChangeLog
+++ b/cpukit/libfs/ChangeLog
@@ -1,5 +1,11 @@
2003-10-22 Joel Sherrill <joel@OARcorp.com>
+ PR 440/filesystem
+ * src/dosfs/fat_fat_operations.c: Improve write speed with FAT12 and
+ FAT16 filesystems. Previously merged on 4.6 branch.
+
+2003-10-22 Joel Sherrill <joel@OARcorp.com>
+
* ChangeLog: Correct line length.
2003-10-21 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
diff --git a/cpukit/libfs/src/dosfs/fat_fat_operations.c b/cpukit/libfs/src/dosfs/fat_fat_operations.c
index a0bdc976fc..b0afce07ac 100644
--- a/cpukit/libfs/src/dosfs/fat_fat_operations.c
+++ b/cpukit/libfs/src/dosfs/fat_fat_operations.c
@@ -63,9 +63,8 @@ fat_scan_fat_for_free_clusters(
if (count == 0)
return rc;
- /*if ((fs_info->vol.type & FAT_FAT32) &&
- (fs_info->vol.next_cl != FAT_UNDEFINED_VALUE))*/
- if (fs_info->vol.next_cl != FAT_UNDEFINED_VALUE)
+ if ((fs_info->vol.type & FAT_FAT32) &&
+ (fs_info->vol.next_cl != FAT_UNDEFINED_VALUE))
cl4find = fs_info->vol.next_cl;
/*
@@ -133,12 +132,12 @@ fat_scan_fat_for_free_clusters(
/* have we satisfied request ? */
if (*cls_added == count)
{
- /*if (fs_info->vol.type & FAT_FAT32)
- {*/
+ if (fs_info->vol.type & FAT_FAT32)
+ {
fs_info->vol.next_cl = save_cln;
if (fs_info->vol.free_cls != 0xFFFFFFFF)
fs_info->vol.free_cls -= (*cls_added);
- /*}*/
+ }
*last_cl = save_cln;
fat_buf_release(fs_info);
return rc;
@@ -150,13 +149,12 @@ fat_scan_fat_for_free_clusters(
cl4find = 2;
}
- /*if (fs_info->vol.type & FAT_FAT32)
- {*/
+ if (fs_info->vol.type & FAT_FAT32)
+ {
fs_info->vol.next_cl = save_cln;
if (fs_info->vol.free_cls != 0xFFFFFFFF)
fs_info->vol.free_cls -= (*cls_added);
- /*}*/
-
+ }
*last_cl = save_cln;
fat_buf_release(fs_info);
return RC_OK;
@@ -189,11 +187,9 @@ fat_free_fat_clusters_chain(
rc = fat_get_fat_cluster(mt_entry, cur_cln, &next_cln);
if ( rc != RC_OK )
{
- /*if ((fs_info->vol.type & FAT_FAT32) &&
- (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE))*/
- if(fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)
+ if ((fs_info->vol.type & FAT_FAT32) &&
+ (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE))
fs_info->vol.free_cls += freed_cls_cnt;
-
fat_buf_release(fs_info);
return rc;
}
@@ -206,12 +202,12 @@ fat_free_fat_clusters_chain(
cur_cln = next_cln;
}
- /*if (fs_info->vol.type & FAT_FAT32)
- {*/
+ if (fs_info->vol.type & FAT_FAT32)
+ {
fs_info->vol.next_cl = chain;
if (fs_info->vol.free_cls != FAT_UNDEFINED_VALUE)
fs_info->vol.free_cls += freed_cls_cnt;
- /*}*/
+ }
fat_buf_release(fs_info);
if (rc1 != RC_OK)