From: Nikolay Borisov <nborisov@suse.com>
To: linux-btrfs@vger.kernel.org
Cc: Nikolay Borisov <nborisov@suse.com>
Subject: [PATCH 0/8] Removal of optional hooks from struct extent_io_ops
Date: Thu, 1 Nov 2018 14:09:45 +0200 [thread overview]
Message-ID: <1541074194-22227-1-git-send-email-nborisov@suse.com> (raw)
extent_io_ops has a set of 8 optional hooks which are set only for data and
freespace inodes. The majority of them actually deal with delallocs in one way
or another. Inspecting the code it transpired that there is actually no need to
have them as function pointers in a structure. Data/freespace inodes can easily
be distinguished from the btree_inode (which is pending removal anyway) by
inspecting extent_io_tree::private_data. This member is set by all data/freespace
inodes. This series exploits this fact to remove the majority of them. Others,
such as fill_delalloc, writepage_start_hook and writepage_end_io_hook are always
called from the data writeout path and can be directly called without having to
check whether the respective pointers are set.
This series has undergone multiple xfstest runs and no regressions were
identified. Additionally all but run_delalloc_range functions are given more
descriptive names, related to their actual intent.
Nikolay Borisov (8):
btrfs: Remove extent_io_ops::fill_delalloc
btrfs: Remove extent_io_ops::writepage_start_hook
btrfs: Remove extent_io_ops::writepage_end_io_hook
btrfs: Remove extent_io_ops::check_extent_io_range callback
btrfs: Remove extent_io_ops::set_bit_hook extent_io callback
btrfs: Remove extent_io_ops::clear_bit_hook callback
btrfs: Remove extent_io_ops::merge_extent_hook callback
btrfs: Remove extent_io_ops::split_extent_hook callback
fs/btrfs/compression.c | 11 ++--
fs/btrfs/ctree.h | 15 +++++
fs/btrfs/extent_io.c | 131 +++++++++++++++++----------------------
fs/btrfs/extent_io.h | 24 -------
fs/btrfs/inode.c | 86 +++++++++----------------
fs/btrfs/tests/extent-io-tests.c | 2 +-
6 files changed, 105 insertions(+), 164 deletions(-)
--
2.7.4
next reply other threads:[~2018-11-01 12:09 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-01 12:09 Nikolay Borisov [this message]
2018-11-01 12:09 ` [PATCH 1/8] btrfs: Remove extent_io_ops::fill_delalloc Nikolay Borisov
2018-11-01 18:59 ` Josef Bacik
2018-11-05 16:20 ` David Sterba
2018-11-01 12:09 ` [PATCH 2/8] btrfs: Remove extent_io_ops::writepage_start_hook Nikolay Borisov
2018-11-01 19:00 ` Josef Bacik
2018-11-01 12:09 ` [PATCH 3/8] btrfs: Remove extent_io_ops::writepage_end_io_hook Nikolay Borisov
2018-11-01 19:03 ` Josef Bacik
2018-11-02 6:15 ` Nikolay Borisov
2018-11-01 12:09 ` [PATCH 4/8] btrfs: Remove extent_io_ops::check_extent_io_range callback Nikolay Borisov
2018-11-01 19:05 ` Josef Bacik
2018-11-01 12:09 ` [PATCH 5/8] btrfs: Remove extent_io_ops::set_bit_hook extent_io callback Nikolay Borisov
2018-11-01 19:06 ` Josef Bacik
2018-11-01 12:09 ` [PATCH 6/8] btrfs: Remove extent_io_ops::clear_bit_hook callback Nikolay Borisov
2018-11-01 19:08 ` Josef Bacik
2018-11-01 12:09 ` [PATCH 7/8] btrfs: Remove extent_io_ops::merge_extent_hook callback Nikolay Borisov
2018-11-01 19:11 ` Josef Bacik
2018-11-01 12:09 ` [PATCH 8/8] btrfs: Remove extent_io_ops::split_extent_hook callback Nikolay Borisov
2018-11-01 19:12 ` Josef Bacik
2018-11-05 16:21 ` [PATCH 0/8] Removal of optional hooks from struct extent_io_ops David Sterba
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1541074194-22227-1-git-send-email-nborisov@suse.com \
--to=nborisov@suse.com \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.