Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1470896
| From | Jaegeuk Kim <jaegeuk@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/2] f2fs: fix to update node page under cp_rwsem |
| Date | 2016-08-26 19:10 +0200 |
| Message-ID | <sasNH-1u2-9@gated-at.bofh.it> (permalink) |
| References | <sas1j-XY-5@gated-at.bofh.it> <sas1j-XY-15@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sat, Aug 27, 2016 at 12:14:32AM +0800, Chao Yu wrote:
> From: Chao Yu <yuchao0@huawei.com>
>
> Update node page under cp_rwsem in order to keep data consistency
> during writting checkpoint.
>
> Signed-off-by: Chao Yu <yuchao0@huawei.com>
> ---
> fs/f2fs/inode.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/fs/f2fs/inode.c b/fs/f2fs/inode.c
> index 9ac5efc..1057c73 100644
> --- a/fs/f2fs/inode.c
> +++ b/fs/f2fs/inode.c
> @@ -377,8 +377,11 @@ retry:
> goto retry;
> }
>
> - if (err)
> + if (err) {
> + f2fs_lock_op(sbi);
> update_inode_page(inode);
> + f2fs_unlock_op(sbi);
> + }
Any corner case?
Now, it allows updating node page when checkpoint is doing.
Thanks,
> sb_end_intwrite(inode->i_sb);
> no_delete:
> stat_dec_inline_xattr(inode);
> --
> 2.7.2
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 1/2] f2fs: do in batch synchronously readahead during GC Chao Yu <chao@kernel.org> - 2016-08-26 18:20 +0200
[PATCH 2/2] f2fs: fix to update node page under cp_rwsem Chao Yu <chao@kernel.org> - 2016-08-26 18:20 +0200
Re: [PATCH 2/2] f2fs: fix to update node page under cp_rwsem Jaegeuk Kim <jaegeuk@kernel.org> - 2016-08-26 19:10 +0200
Re: [PATCH 2/2] f2fs: fix to update node page under cp_rwsem Chao Yu <yuchao0@huawei.com> - 2016-08-27 10:40 +0200
Re: [PATCH 2/2] f2fs: fix to update node page under cp_rwsem Jaegeuk Kim <jaegeuk@kernel.org> - 2016-08-29 18:50 +0200
csiph-web