Re: [PATCH 1/1] fs: global sync to not clear error status of individual inodes

From: Junichi Nomura
Date: Tue Sep 15 2015 - 21:00:42 EST


On 09/16/15 00:20, Tejun Heo wrote:
>> @@ -2121,7 +2121,13 @@ static void wait_sb_inodes(struct super_block *sb)
>> iput(old_inode);
>> old_inode = inode;
>>
>> - filemap_fdatawait(mapping);
>> + /*
>> + * Wait for on-going writeback to complete
>> + * but not consume error status on this mapping.
> ^don't
>
>> + * Otherwise application may fail to catch writeback error
>
> mapping; otherwise,
>
>> + * using fsync(2).
>> + */
>
> Can you please re-flow the comment so that it's filling up to, say, 72
> or 76 or whatever column?

I'll fix them.

>> - filemap_fdatawait(bdev->bd_inode->i_mapping);
>> + filemap_fdatawait_keep_errors(bdev->bd_inode->i_mapping);
>
> Maybe it'd be better to describe what's going on in detail in the
> function comment of filemat_fdatawait_keep_errors() and refer to that
> from its callers?

Thanks, that seems better.
I'll also extend function comments of filemap_fdatawait so that the
difference becomes clear.

--
Jun'ichi Nomura, NEC Corporation--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/