Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1514669
| From | Chao Yu <chao@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 1/2] f2fs: fix wrong i_atime recovery |
| Date | 2016-11-03 17:30 +0100 |
| Message-ID | <szt3P-6jb-1@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
From: Chao Yu <yuchao0@huawei.com> Shouldn't update in-memory i_atime with on-disk i_mtime of inode when recovering inode. Shuoran found this bug which is hidden for a long time, honour is belong to him. Signed-off-by: Shuoran Liu <liushuoran@huawei.com> Signed-off-by: Chao Yu <yuchao0@huawei.com> --- fs/f2fs/recovery.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/f2fs/recovery.c b/fs/f2fs/recovery.c index 2fc84a9..d2ba4da 100644 --- a/fs/f2fs/recovery.c +++ b/fs/f2fs/recovery.c @@ -180,10 +180,10 @@ static void recover_inode(struct inode *inode, struct page *page) inode->i_mode = le16_to_cpu(raw->i_mode); f2fs_i_size_write(inode, le64_to_cpu(raw->i_size)); - inode->i_atime.tv_sec = le64_to_cpu(raw->i_mtime); + inode->i_atime.tv_sec = le64_to_cpu(raw->i_atime); inode->i_ctime.tv_sec = le64_to_cpu(raw->i_ctime); inode->i_mtime.tv_sec = le64_to_cpu(raw->i_mtime); - inode->i_atime.tv_nsec = le32_to_cpu(raw->i_mtime_nsec); + inode->i_atime.tv_nsec = le32_to_cpu(raw->i_atime_nsec); inode->i_ctime.tv_nsec = le32_to_cpu(raw->i_ctime_nsec); inode->i_mtime.tv_nsec = le32_to_cpu(raw->i_mtime_nsec); -- 2.10.1
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH 1/2] f2fs: fix wrong i_atime recovery Chao Yu <chao@kernel.org> - 2016-11-03 17:30 +0100
[PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Chao Yu <chao@kernel.org> - 2016-11-03 17:30 +0100
Re: [PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Jaegeuk Kim <jaegeuk@kernel.org> - 2016-11-03 19:10 +0100
Re: [PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Chao Yu <yuchao0@huawei.com> - 2016-11-04 09:40 +0100
Re: [PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Jaegeuk Kim <jaegeuk@kernel.org> - 2016-11-05 00:00 +0100
Re: [PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Chao Yu <chao@kernel.org> - 2016-11-05 04:20 +0100
Re: [PATCH 2/2] f2fs: don't skip recovering inode depend on i_times Jaegeuk Kim <jaegeuk@kernel.org> - 2016-11-05 08:10 +0100
csiph-web