From: Kent Overstreet <kent.overstreet@linux.dev>
To: linux-bcachefs@vger.kernel.org
Cc: Kent Overstreet <kent.overstreet@linux.dev>
Subject: [PATCH 0/9] transaction restarts and other iterator work
Date: Sat, 26 Oct 2024 20:51:29 -0400 [thread overview]
Message-ID: <20241027005141.2337634-1-kent.overstreet@linux.dev> (raw)
batch of various btree iterator patches
- transaction restart injection, asserts: there were some mishandled
transaction restarts, now all fixed, and this is the debug code I used
to find them.
The tests now run with transaction restart injection on, so any new
bugs will be quickly caught in the future.
- btree_iter_peek_prev() improvements: it now works with the journal
keys overlay, which means we now should have the option of doing
journal replay in the background should we ever need to,
More importantly it now supports an "end of iteration range" argument;
this is required for correctness in BTREE_ITER_filter_snapshots mode,
otherwise we could keep going into the next inode, which might belong
to a different snapshot tree, and we never find any keys that are
visible that we can return.
This fixes a bug in reconstruct_inode(), in fsck.
Kent Overstreet (9):
bcachefs: Assert we're not in a restart in bch2_trans_put()
bcachefs: Better in_restart error
bcachefs: CONFIG_BCACHEFS_INJECT_TRANSACTION_RESTARTS
bcachefs: Assert that we're not violating key cache coherency rules
bcachefs: Rename btree_iter_peek_upto() -> btree_iter_peek_max()
bcachefs: Simplify btree_iter_peek() filter_snapshots
bcachefs: Kill unnecessary iter_rewind() in bkey_get_empty_slot()
bcachefs: Implement bch2_btree_iter_prev_min()
bcachefs: peek_prev_min(): Search forwards for extents, snapshots
fs/bcachefs/Kconfig | 7 +
fs/bcachefs/alloc_background.c | 6 +-
fs/bcachefs/btree_gc.c | 2 +-
fs/bcachefs/btree_iter.c | 459 ++++++++++++++++++++-----------
fs/bcachefs/btree_iter.h | 60 ++--
fs/bcachefs/btree_journal_iter.c | 50 +++-
fs/bcachefs/btree_journal_iter.h | 4 +-
fs/bcachefs/btree_key_cache.c | 13 +-
fs/bcachefs/btree_trans_commit.c | 4 +
fs/bcachefs/btree_types.h | 6 +
fs/bcachefs/btree_update.c | 13 +-
fs/bcachefs/dirent.c | 4 +-
fs/bcachefs/ec.c | 2 +-
fs/bcachefs/errcode.h | 1 -
fs/bcachefs/extent_update.c | 2 +-
fs/bcachefs/fs-io-pagecache.c | 2 +-
fs/bcachefs/fs-io.c | 8 +-
fs/bcachefs/fs.c | 2 +-
fs/bcachefs/fsck.c | 12 +-
fs/bcachefs/inode.c | 6 +-
fs/bcachefs/io_misc.c | 8 +-
fs/bcachefs/io_write.c | 4 +-
fs/bcachefs/movinggc.c | 2 +-
fs/bcachefs/reflink.c | 2 +-
fs/bcachefs/str_hash.h | 6 +-
fs/bcachefs/subvolume.h | 12 +-
fs/bcachefs/tests.c | 26 +-
fs/bcachefs/xattr.c | 2 +-
28 files changed, 482 insertions(+), 243 deletions(-)
--
2.45.2
next reply other threads:[~2024-10-27 0:51 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-27 0:51 Kent Overstreet [this message]
2024-10-27 0:51 ` [PATCH 1/9] bcachefs: Assert we're not in a restart in bch2_trans_put() Kent Overstreet
2024-10-27 0:51 ` [PATCH 2/9] bcachefs: Better in_restart error Kent Overstreet
2024-10-27 0:51 ` [PATCH 3/9] bcachefs: CONFIG_BCACHEFS_INJECT_TRANSACTION_RESTARTS Kent Overstreet
2024-10-27 0:51 ` [PATCH 4/9] bcachefs: Assert that we're not violating key cache coherency rules Kent Overstreet
2024-10-27 0:51 ` [PATCH 5/9] bcachefs: Rename btree_iter_peek_upto() -> btree_iter_peek_max() Kent Overstreet
2024-10-27 0:51 ` [PATCH 6/9] bcachefs: Simplify btree_iter_peek() filter_snapshots Kent Overstreet
2024-10-27 0:51 ` [PATCH 7/9] bcachefs: Kill unnecessary iter_rewind() in bkey_get_empty_slot() Kent Overstreet
2024-10-27 0:51 ` [PATCH 8/9] bcachefs: Implement bch2_btree_iter_prev_min() Kent Overstreet
2024-10-27 0:51 ` [PATCH 9/9] bcachefs: peek_prev_min(): Search forwards for extents, snapshots Kent Overstreet
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=20241027005141.2337634-1-kent.overstreet@linux.dev \
--to=kent.overstreet@linux.dev \
--cc=linux-bcachefs@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox