linux-hardened/fs/btrfs/tests
Nikolay Borisov 3dc9dc8969 btrfs: eliminate total_size parameter from setup_items_for_insert
The value of this argument can be derived from the total_data as it's
simply the value of the data size + size of btrfs_items being touched.
Move the parameter calculation inside the function. This results in a
simpler interface and also a minor size reduction:

./scripts/bloat-o-meter ctree.original fs/btrfs/ctree.o
add/remove: 0/0 grow/shrink: 0/3 up/down: 0/-34 (-34)
Function                                     old     new   delta
btrfs_duplicate_item                         260     259      -1
setup_items_for_insert                      1200    1190     -10
btrfs_insert_empty_items                     177     154     -23

Reviewed-by: Josef Bacik <josef@toxicpanda.com>
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
2020-10-07 12:13:18 +02:00
..
btrfs-tests.c btrfs: kill the subvol_srcu 2020-03-23 17:02:00 +01:00
btrfs-tests.h btrfs: selftests: Add support for dummy devices 2020-01-23 17:24:34 +01:00
extent-buffer-tests.c btrfs: eliminate total_size parameter from setup_items_for_insert 2020-10-07 12:13:18 +02:00
extent-io-tests.c btrfs: Correctly handle empty trees in find_first_clear_extent_bit 2020-01-31 14:01:29 +01:00
extent-map-tests.c btrfs: Add self-tests for btrfs_rmap_block 2020-01-23 17:24:35 +01:00
free-space-tests.c btrfs: rename btrfs_block_group_cache 2019-11-18 17:51:51 +01:00
free-space-tree-tests.c btrfs: tests: remove if duplicate in __check_free_space_extents() 2020-07-27 12:55:27 +02:00
inode-tests.c btrfs: eliminate total_size parameter from setup_items_for_insert 2020-10-07 12:13:18 +02:00
qgroup-tests.c btrfs: don't take an extra root ref at allocation time 2020-03-23 17:01:59 +01:00