aboutsummaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorStefan Brüns2016-09-11 22:51:41 +0200
committerTom Rini2016-09-23 08:55:57 -0400
commitae1755be37e3d51af631ff2df12189c9fdc3e1d7 (patch)
tree138a5a53cde13a224e2acade32e6fd79f9d06dda /fs
parent3c0ed9c3a561ca744b2b76921bb8352ba2340669 (diff)
fs/fat: Correct description of determine_fatent function
Current description does not match the function behaviour. Signed-off-by: Stefan Brüns <stefan.bruens@rwth-aachen.de> Acked-by: Lukasz Majewski <l.majewski@samsung.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/fat/fat_write.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/fat/fat_write.c b/fs/fat/fat_write.c
index babe9c8dd02..0583af310a5 100644
--- a/fs/fat/fat_write.c
+++ b/fs/fat/fat_write.c
@@ -528,7 +528,8 @@ static int set_fatent_value(fsdata *mydata, __u32 entry, __u32 entry_value)
}
/*
- * Determine the entry value at index 'entry' in a FAT (16/32) table
+ * Determine the next free cluster after 'entry' in a FAT (16/32) table
+ * and link it to 'entry'. EOC marker is not set on returned entry.
*/
static __u32 determine_fatent(fsdata *mydata, __u32 entry)
{
@@ -537,6 +538,7 @@ static __u32 determine_fatent(fsdata *mydata, __u32 entry)
while (1) {
next_fat = get_fatent_value(mydata, next_entry);
if (next_fat == 0) {
+ /* found free entry, link to entry */
set_fatent_value(mydata, entry, next_entry);
break;
}