mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 05:31:08 -04:00
ext4: Fix ext4_should_journal_data() for EA inodes
Similarly to directories, EA inodes do only journalled modifications to their data. Change ext4_should_journal_data() to return true for them so that we don't have to special-case them during truncate. Signed-off-by: Jan Kara <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Theodore Ts'o <[email protected]>
This commit is contained in:
1 parent
65db869c75
commit
321238fbfb
1 file changed
+1
@@ -407,6 +407,7 @@ static inline int ext4_inode_journal_mode(struct inode *inode)
|
||||
return EXT4_INODE_WRITEBACK_DATA_MODE; /* writeback */
|
||||
/* We do not support data journalling with delayed allocation */
|
||||
if (!S_ISREG(inode->i_mode) ||
|
||||
ext4_test_inode_flag(inode, EXT4_INODE_EA_INODE) ||
|
||||
test_opt(inode->i_sb, DATA_FLAGS) == EXT4_MOUNT_JOURNAL_DATA ||
|
||||
(ext4_test_inode_flag(inode, EXT4_INODE_JOURNAL_DATA) &&
|
||||
!test_opt(inode->i_sb, DELALLOC))) {
|
||||
|
||||
Reference in new issue
Block a user