btrfs: do not try to unlock the extent for non-subpage metadata reads
authorChristoph Hellwig <hch@lst.de>
Wed, 3 May 2023 15:24:29 +0000 (17:24 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 19 Jun 2023 11:59:27 +0000 (13:59 +0200)
commit3d66b4b27d2b7f5e74071256acea38108f9dbeb5
treef66cff44e95455f73258e11b493baa8bf080e357
parent046b562b20a5cfe205fb78c6f8a1a8b74f01d303
btrfs: do not try to unlock the extent for non-subpage metadata reads

Only subpage metadata reads lock the extent.  Don't try to unlock it and
waste cycles in the extent tree lookup for PAGE_SIZE or larger metadata.

Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent_io.c