]> git.ipfire.org Git - thirdparty/linux.git/commit
ext4: make __es_remove_extent() check extent status
authorZhang Yi <yi.zhang@huawei.com>
Sat, 29 Nov 2025 10:32:42 +0000 (18:32 +0800)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 18 Jan 2026 16:23:33 +0000 (11:23 -0500)
commit42ad7b23b335835548fecc757d6627b67cd5f0b4
tree3b454677bc295395edb0c7c0b01fc34d2e2131b1
parentef46e0d70014cad87dc18e7d292e7c75c0ef30c8
ext4: make __es_remove_extent() check extent status

Currently, __es_remove_extent() unconditionally removes extent status
entries within the specified range. In order to prepare for extending
the ext4_es_cache_extent() function to cache on-disk extents, which may
overwrite some existing short-length extents with the same status, allow
__es_remove_extent() to check the specified extent type before removing
it, and return error and pass out the conflicting extent if the status
does not match.

Signed-off-by: Zhang Yi <yi.zhang@huawei.com>
Reviewed-by: Baokun Li <libaokun1@huawei.com>
Message-ID: <20251129103247.686136-11-yi.zhang@huaweicloud.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/extents_status.c