Skip to content

Commit 944df75

Browse files
Christoph HellwigChandan Babu R
authored andcommitted
xfs: consider minlen sized extents in xfs_rtallocate_extent_block
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>
1 parent b5785f6 commit 944df75

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

fs/xfs/xfs_rtalloc.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ xfs_rtallocate_extent_block(
309309
/*
310310
* Searched the whole thing & didn't find a maxlen free extent.
311311
*/
312-
if (minlen < maxlen && besti != -1) {
312+
if (minlen <= maxlen && besti != -1) {
313313
xfs_rtxlen_t p; /* amount to trim length by */
314314

315315
/*

0 commit comments

Comments
 (0)