summaryrefslogtreecommitdiffstats
path: root/fs/ext4
diff options
context:
space:
mode:
authorPrzemyslaw Marczak <p.marczak@samsung.com>2015-02-17 15:31:52 +0100
committerTom Rini <trini@konsulko.com>2015-03-05 20:49:42 -0500
commit22b7509efb35d7bda05260d5730124dbdc3ea9dc (patch)
treeca04865b2a34f83b14ca04cdcbd85112eddea3ec /fs/ext4
parentb31f9d7a4aea23a8a9d007356a2b61e503e69daa (diff)
downloadu-boot-22b7509efb35d7bda05260d5730124dbdc3ea9dc.tar.gz
u-boot-22b7509efb35d7bda05260d5730124dbdc3ea9dc.tar.xz
u-boot-22b7509efb35d7bda05260d5730124dbdc3ea9dc.zip
fs: ext4 write: return file len on success
After rework of the file system API, the size of ext4 write was missed. This causes printing unreliable write size at the end of the file system write operation. Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com> Cc: Sjoerd Simons <sjoerd.simons@collabora.co.uk> Cc: Lukasz Majewski <l.majewski@samsung.com> Cc: Simon Glass <sjg@chromium.org> Tested-by: Stephen Warren <swarren@nvidia.com>
Diffstat (limited to 'fs/ext4')
-rw-r--r--fs/ext4/ext4_write.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ext4/ext4_write.c b/fs/ext4/ext4_write.c
index f7c52cc4cc..fbc4c4b1cc 100644
--- a/fs/ext4/ext4_write.c
+++ b/fs/ext4/ext4_write.c
@@ -1000,10 +1000,13 @@ int ext4_write_file(const char *filename, void *buf, loff_t offset,
}
ext4fs_close();
+ *actwrite = len;
+
return 0;
fail:
ext4fs_close();
+ *actwrite = 0;
return -1;
}