summaryrefslogtreecommitdiff
path: root/tools/lib/python/kdoc/kdoc_re.py
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2025-11-21 15:56:14 +0000
committerDavid Sterba <dsterba@suse.com>2025-11-25 01:53:33 +0100
commit1c3e03b34042c2dff15d7f262b768908e4b02537 (patch)
treeea7054e1d85e39e370dbdde6da1788e9b1a93b73 /tools/lib/python/kdoc/kdoc_re.py
parent10934c131f9bcfb616dd8be9456f11efd6b240ec (diff)
btrfs: remove redundant zero/NULL initializations in btrfs_alloc_root()
We have allocated the root with kzalloc() so all the memory is already zero initialized, therefore it's redundant to assign 0 and NULL to several of the root members. Remove all of them except the atomic initializations since atomic_t is an opaque type and it's not a good practice to assume its internals. This slightly reduces the binary size. With gcc 14.2.0-19 from Debian on x86_64, before this change: $ size fs/btrfs/btrfs.ko text data bss dec hex filename 1939404 162963 15592 2117959 205147 fs/btrfs/btrfs.ko After this change: $ size fs/btrfs/btrfs.ko text data bss dec hex filename 1939212 162963 15592 2117767 205087 fs/btrfs/btrfs.ko Reviewed-by: Qu Wenruo <wqu@suse.com> Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'tools/lib/python/kdoc/kdoc_re.py')
0 files changed, 0 insertions, 0 deletions