Re: [f2fs-dev] [PATCH] f2fs: change i_compr_blocks of inode to atomic value

2020-09-02 Thread Chao Yu
On 2020/9/3 9:43, Daeho Jeong wrote: And how about this atomic64 to just atomic? As you mentioned before, we don't need a 64bit value for i_compr_blocks of inode. Yup, I think atomic type is enough for both f2fs_inode_info.i_compr_blocks and f2fs_sb_info.compr_blocks. Thanks, 2020년 9월 3일 (목

Re: [f2fs-dev] [PATCH] f2fs: change i_compr_blocks of inode to atomic value

2020-09-02 Thread Daeho Jeong
And how about this atomic64 to just atomic? As you mentioned before, we don't need a 64bit value for i_compr_blocks of inode. 2020년 9월 3일 (목) 오전 10:08, Chao Yu 님이 작성: > > On 2020/9/2 14:29, Daeho Jeong wrote: > > From: Daeho Jeong > > > > writepages() can be concurrently invoked for the same file

Re: [f2fs-dev] [PATCH] f2fs: change i_compr_blocks of inode to atomic value

2020-09-02 Thread Chao Yu
On 2020/9/2 14:29, Daeho Jeong wrote: From: Daeho Jeong writepages() can be concurrently invoked for the same file by different threads such as a thread fsyncing the file and a kworker kernel thread. So, changing i_compr_blocks without protection is racy and we need to protect it by changing it