Re: [PATCH for 5.4 1/3] ext4: check for out-of-order index extents in ext4_valid_extent_entries()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Feb 17, 2022 at 02:59:12PM -0800, Leah Rumancik wrote:
> From: Zhang Yi <yi.zhang@xxxxxxxxxx>
> 
> commit 8dd27fecede55e8a4e67eef2878040ecad0f0d33 upstream.
> 
> After commit 5946d089379a ("ext4: check for overlapping extents in
> ext4_valid_extent_entries()"), we can check out the overlapping extent
> entry in leaf extent blocks. But the out-of-order extent entry in index
> extent blocks could also trigger bad things if the filesystem is
> inconsistent. So this patch add a check to figure out the out-of-order
> index extents and return error.
> 
> [Added pblk argument to ext4_valid_extent_entries because pblk is
> updated in the case of overlapping extents. This argument was added
> in commit 54d3adbc29f0c7c53890da1683e629cd220d7201.]
> 
> Signed-off-by: Zhang Yi <yi.zhang@xxxxxxxxxx>
> Reviewed-by: Theodore Ts'o <tytso@xxxxxxx>
> Link: https://lore.kernel.org/r/20210908120850.4012324-2-yi.zhang@xxxxxxxxxx
> Signed-off-by: Theodore Ts'o <tytso@xxxxxxx>
> Signed-off-by: Leah Rumancik <leah.rumancik@xxxxxxxxx>
> ---
>  fs/ext4/extents.c | 21 ++++++++++++++-------
>  1 file changed, 14 insertions(+), 7 deletions(-)

All now queued up, thanks.

greg k-h



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux