OSDN Git Service

xfs: simplify xfs_rmap_lookup_le call sites
authorDarrick J. Wong <djwong@kernel.org>
Tue, 26 Apr 2022 01:37:06 +0000 (18:37 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Wed, 27 Apr 2022 17:47:19 +0000 (10:47 -0700)
commit5b7ca8b313621907d80460bfcc1fa876d2a38488
treea2f4bb85fcc4325e2091446877c81a3a4b8a38d1
parentc46eef34830e51ae7fe4b8371837c586448c3078
xfs: simplify xfs_rmap_lookup_le call sites

Most callers of xfs_rmap_lookup_le will retrieve the btree record
immediately if the lookup succeeds.  The overlapped version of this
function (xfs_rmap_lookup_le_range) will return the record if the lookup
succeeds, so make the regular version do it too.  Get rid of the useless
len argument, since it's not part of the lookup key.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_rmap.c
fs/xfs/libxfs/xfs_rmap.h
fs/xfs/scrub/bmap.c