]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
xfs: consider minlen sized extents in xfs_rtallocate_extent_block
authorChristoph Hellwig <hch@lst.de>
Wed, 27 Mar 2024 00:12:12 +0000 (17:12 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 3 Apr 2024 13:28:46 +0000 (15:28 +0200)
commit08bac45e02c6ada1c6bfcff31d55c96e637b6787
treed115f831f5fc7216650347d1bf3b382350dcd056
parent57a20b6150d39b01a185f1ea8a1cecf64ffe1405
xfs: consider minlen sized extents in xfs_rtallocate_extent_block

commit 944df75958807d56f2db9fdc769eb15dd9f0366a upstream.

[backport: resolve merge conflict due to missing xfs_rtxlen_t type]

minlen is the lower bound on the extent length that the caller can
accept, and maxlen is at this point the maximal available length.
This means a minlen extent is perfectly fine to use, so do it.  This
matches the equivalent logic in xfs_rtallocate_extent_exact that also
accepts a minlen sized extent.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Signed-off-by: Chandan Babu R <chandanbabu@kernel.org>
Signed-off-by: Catherine Hoang <catherine.hoang@oracle.com>
Acked-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/xfs/xfs_rtalloc.c