]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: introduce item_nr token variant helpers
authorJosef Bacik <josef@toxicpanda.com>
Thu, 21 Oct 2021 18:58:34 +0000 (14:58 -0400)
committerDavid Sterba <dsterba@suse.com>
Mon, 3 Jan 2022 14:09:43 +0000 (15:09 +0100)
commit6076c013b44af4f23e12ef343c1303fb06d7af57
treeb15ae897fbd05cbcb229e9d6b1b701c68ed94522
parentce68a81effca2c7ff67cacfa142a7d1b3558fe6e
btrfs: introduce item_nr token variant helpers

The last remaining place where we have the pattern of

item = btrfs_item_nr(slot)
<do something with the item>

are the token helpers.  Handle this by introducing token helpers that
will do the btrfs_item_nr() work inside of the helper itself, and then
convert all users of the btrfs_item token helpers to the new _nr()
variants.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/ctree.c
fs/btrfs/ctree.h