]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
btrfs: add strict extent map alignment checks
authorQu Wenruo <wqu@suse.com>
Wed, 21 Jan 2026 23:08:00 +0000 (09:38 +1030)
committerDavid Sterba <dsterba@suse.com>
Tue, 3 Feb 2026 06:56:19 +0000 (07:56 +0100)
commit71e545d4e33f97258bf7416c132b10a6c1234255
treebcc3f941e1e1c2bd2b2937065b4881c10a0da2d6
parent385c65f8274b8caff75102474c4c9e8a95e6ec4c
btrfs: add strict extent map alignment checks

Currently we do not check the alignment of extent_map structure.

The reasons are the inode and extent-map tests use unaligned values
for start offsets and lengths.

Thankfully those legacy problems are properly addressed by previous
patches, now we can finally put the alignment checks into
validate_extent_map().

Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent_map.c