Matthew Wilcox
2023-Jan-08 21:17 UTC
[Ocfs2-devel] [PATCH 3/7] minix: don't flush page immediately for DIRSYNC directories
On Sun, Jan 08, 2023 at 05:56:41PM +0100, Christoph Hellwig wrote:> @@ -274,9 +280,10 @@ int minix_add_link(struct dentry *dentry, struct inode *inode) > memset (namx + namelen, 0, sbi->s_dirsize - namelen - 2); > de->inode = inode->i_ino; > } > - err = dir_commit_chunk(page, pos, sbi->s_dirsize); > + dir_commit_chunk(page, pos, sbi->s_dirsize); > dir->i_mtime = dir->i_ctime = current_time(dir); > mark_inode_dirty(dir); > + minix_handle_dirsync(dir);Doesn't this need to be: err = minix_handle_dirsync(dir);> @@ -426,7 +436,7 @@ void minix_set_link(struct minix_dir_entry *de, struct page *page, > ((minix3_dirent *) de)->inode = inode->i_ino; > else > de->inode = inode->i_ino; > - err = dir_commit_chunk(page, pos, sbi->s_dirsize); > + dir_commit_chunk(page, pos, sbi->s_dirsize); > } else { > unlock_page(page); > } > --Aren't you missing a call to minix_handle_dirsync() in this function?
Christoph Hellwig
2023-Jan-10 08:22 UTC
[Ocfs2-devel] [PATCH 3/7] minix: don't flush page immediately for DIRSYNC directories
On Sun, Jan 08, 2023 at 09:17:26PM +0000, Matthew Wilcox wrote:> > + dir_commit_chunk(page, pos, sbi->s_dirsize); > > dir->i_mtime = dir->i_ctime = current_time(dir); > > mark_inode_dirty(dir); > > + minix_handle_dirsync(dir); > > Doesn't this need to be: > > err = minix_handle_dirsync(dir);Yes, fixed.> > > @@ -426,7 +436,7 @@ void minix_set_link(struct minix_dir_entry *de, struct page *page, > > ((minix3_dirent *) de)->inode = inode->i_ino; > > else > > de->inode = inode->i_ino; > > - err = dir_commit_chunk(page, pos, sbi->s_dirsize); > > + dir_commit_chunk(page, pos, sbi->s_dirsize); > > } else { > > unlock_page(page); > > } > > -- > > Aren't you missing a call to minix_handle_dirsync() in this function?Yes, fixed.