From: Johannes Thumshirn <jth@kernel.org>
To: David Sterba <dsterba@suse.com>
Cc: Nikolay Borisov <nborisov@suse.com>, Qu Wenruo <wqu@suse.com>,
Linux BTRFS Mailinglist <linux-btrfs@vger.kernel.org>,
Johannes Thumshirn <jth@kernel.org>
Subject: [PATCH v5 0/2] remove BUG_ON()s in btrfs_close_one_device()
Date: Wed, 4 Dec 2019 14:36:37 +0100 [thread overview]
Message-ID: <20191204133639.2382-1-jth@kernel.org> (raw)
This series attempts to remove the BUG_ON()s in btrfs_close_one_device().
Therefore some reorganization of btrfs_close_one_device() was needed, to
avoid the memory allocation.
This series has passed fstests without any deviation from the baseline.
Changes to v4:
- Clear dev_stat_ccnt on removal (Dave)
- Don't clear BTRFS_DEV_STATE_MISSING and BTRFS_DEV_STATE_FS_METADATA as
they'll be handled elsewhere
- Release extent_io_tree (fstests)
Changes to v3:
- Clear BTRFS_DEV_STATE_WRITEABLE after calling btrfs_close_bdev() so
btrfs_close_bdev() can call sync_blockdev() and invalidate_bdev() (Nikolay)
Changes to v2:
- Completly different approach to the origianl patchset, instead of handling
eventual allocation failures.
- Dropped already merged patches for ' btrfs_fs_devices::rotating' and
'btrfs_fs_devices::seeding'
- Kept the 1st patch of the old series, as it's a nice cleanup
Changes to v1:
- Fixed the decremt of btrfs_fs_devices::seeding.
- In addition to this, I've added two patches changing btrfs_fs_devices::seeding
and btrfs_fs_devices::rotating to bool, as they are in fact used as booleans.
Johannes Thumshirn (2):
btrfs: decrement number of open devices after closing the device not
before
btrfs: reset device back to allocation state when removing
fs/btrfs/volumes.c | 31 ++++++++++++-------------------
1 file changed, 12 insertions(+), 19 deletions(-)
--
2.20.1 (Apple Git-117)
next reply other threads:[~2019-12-04 13:37 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-04 13:36 Johannes Thumshirn [this message]
2019-12-04 13:36 ` [PATCH v5 1/2] btrfs: decrement number of open devices after closing the device not before Johannes Thumshirn
2019-12-04 13:36 ` [PATCH v5 2/2] btrfs: reset device back to allocation state when removing Johannes Thumshirn
2019-12-10 10:10 ` [PATCH v5 0/2] remove BUG_ON()s in btrfs_close_one_device() 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=20191204133639.2382-1-jth@kernel.org \
--to=jth@kernel.org \
--cc=dsterba@suse.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=nborisov@suse.com \
--cc=wqu@suse.com \
/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.