mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-10 12:57:06 +09:00
ext4: online defrag is not supported for journaled files
commit f066055a34 upstream.
Proper block swap for inodes with full journaling enabled is
truly non obvious task. In order to be on a safe side let's
explicitly disable it for now.
Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
7f5397abbb
commit
48fa0772b9
@@ -1209,7 +1209,12 @@ ext4_move_extents(struct file *o_filp, struct file *d_filp,
|
||||
orig_inode->i_ino, donor_inode->i_ino);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
/* TODO: This is non obvious task to swap blocks for inodes with full
|
||||
jornaling enabled */
|
||||
if (ext4_should_journal_data(orig_inode) ||
|
||||
ext4_should_journal_data(donor_inode)) {
|
||||
return -EINVAL;
|
||||
}
|
||||
/* Protect orig and donor inodes against a truncate */
|
||||
ret1 = mext_inode_double_lock(orig_inode, donor_inode);
|
||||
if (ret1 < 0)
|
||||
|
||||
Reference in New Issue
Block a user