@@ -28,14 +28,16 @@
* wait == 1 case since in that case write_inode() functions do
* sync_dirty_buffer() and thus effectively write one block at a time.
*/
-static int __sync_filesystem(struct super_block *sb, int wait)
+static int __sync_filesystem(struct super_block *sb, int wait, errseq_t *since)
{
+ int ret = 0;
+
if (wait)
sync_inodes_sb(sb);
else
writeback_inodes_sb(sb, WB_REASON_SYNC);
- return call_sync_fs(sb, wait, NULL);
+ return call_sync_fs(sb, wait, since);
}
/*
@@ -59,10 +61,10 @@ int sync_filesystem(struct super_block *sb, errseq_t *since)
if (sb_rdonly(sb))
return 0;
- ret = __sync_filesystem(sb, 0);
+ ret = __sync_filesystem(sb, 0, since);
if (ret < 0)
return ret;
- return __sync_filesystem(sb, 1);
+ return __sync_filesystem(sb, 1, since);
}
EXPORT_SYMBOL(sync_filesystem);