ext4: factor out a helper to check the cluster allocation state
authorZhang Yi <yi.zhang@huawei.com>
Fri, 17 May 2024 12:40:03 +0000 (20:40 +0800)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 27 Jun 2024 22:04:50 +0000 (18:04 -0400)
commit49bf6ab4d30b7a39d86a585e0a58f6c449d2e009
tree82834a659a5f96581132dcb6ab957d7acc0aadf0
parent0d66b23d79c750276f791411d81a524549a64852
ext4: factor out a helper to check the cluster allocation state

Factor out a common helper ext4_clu_alloc_state(), check whether the
cluster containing a delalloc block to be added has been allocated or
has delalloc reservation, no logic changes.

Signed-off-by: Zhang Yi <yi.zhang@huawei.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://patch.msgid.link/20240517124005.347221-9-yi.zhang@huaweicloud.com
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/inode.c