From: Christoph Hellwig Date: Mon, 29 Jul 2024 23:22:55 +0000 (-0700) Subject: xfs: remove the xfs_iext_peek_prev_extent call in xfs_bmapi_allocate X-Git-Tag: v6.10.0~24^2~16 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c17f37e2caab8e2f76bb415cd6d2a9a766d7c9e9;p=thirdparty%2Fxfsprogs-dev.git xfs: remove the xfs_iext_peek_prev_extent call in xfs_bmapi_allocate Source kernel commit: a8bb258f703f42c322638022afa16808ca4a7d25 Both callers of xfs_bmapi_allocate already initialize bma->prev, don't redo that in xfs_bmapi_allocate. Signed-off-by: Christoph Hellwig Reviewed-by: "Darrick J. Wong" Signed-off-by: Chandan Babu R --- diff --git a/libxfs/xfs_bmap.c b/libxfs/xfs_bmap.c index a498894f..4279ab83 100644 --- a/libxfs/xfs_bmap.c +++ b/libxfs/xfs_bmap.c @@ -4181,11 +4181,6 @@ xfs_bmapi_allocate( ASSERT(bma->length > 0); ASSERT(bma->length <= XFS_MAX_BMBT_EXTLEN); - if (bma->wasdel) { - if (!xfs_iext_peek_prev_extent(ifp, &bma->icur, &bma->prev)) - bma->prev.br_startoff = NULLFILEOFF; - } - if (bma->flags & XFS_BMAPI_CONTIG) bma->minlen = bma->length; else