ext4: quota macros cleanup
Currently all quota block reservation macros contains hard-coded "2" aka MAXQUOTAS value. This is no good because in some places it is not obvious to understand what does this digit represent. Let's introduce new macro with self descriptive name. Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org> Acked-by: Mingming Cao <cmm@us.ibm.com> Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
This commit is contained in:
committed by
Theodore Ts'o
parent
8aa6790f87
commit
5aca07eb7d
@ -2161,7 +2161,7 @@ ext4_ext_rm_leaf(handle_t *handle, struct inode *inode,
|
||||
correct_index = 1;
|
||||
credits += (ext_depth(inode)) + 1;
|
||||
}
|
||||
credits += 2 * EXT4_QUOTA_TRANS_BLOCKS(inode->i_sb);
|
||||
credits += EXT4_MAXQUOTAS_TRANS_BLOCKS(inode->i_sb);
|
||||
|
||||
err = ext4_ext_truncate_extend_restart(handle, inode, credits);
|
||||
if (err)
|
||||
|
Reference in New Issue
Block a user