]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: add __cold attribute to more functions
authorDavid Sterba <dsterba@suse.com>
Tue, 1 Oct 2019 17:57:35 +0000 (19:57 +0200)
committerDavid Sterba <dsterba@suse.com>
Mon, 18 Nov 2019 11:46:52 +0000 (12:46 +0100)
commit5f64544c5af040f12a27e47932c4d3c43283006c
treebdc1e8adbd8170d5089ce07eca11e6a1b9901cd3
parent9849af85075e0dda33c30a3cd6c992b6ef19a0bb
btrfs: add __cold attribute to more functions

The attribute can mark functions supposed to be called rarely if at all
and the text can be moved to sections far from the other code. The
attribute has been added to several functions already, this patch is
based on hints given by gcc -Wsuggest-attribute=cold.

The net effect of this patch is decrease of btrfs.ko by 1000-1300,
depending on the config options.

Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/disk-io.c
fs/btrfs/disk-io.h
fs/btrfs/super.c
fs/btrfs/volumes.c