diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2019-02-19 17:56:21 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:08:17 -0400 |
commit | 3e5d6c59bec6f989e103e364d6a044a8a77e3a13 (patch) | |
tree | c00719f407f0de297e24b2266668428468f73de3 /fs/bcachefs/btree_update.h | |
parent | 68ef94a63caf214ee238434bf0d4c7a6a32c33a2 (diff) |
bcachefs: Use journal preres for deferred btree updates
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/btree_update.h')
-rw-r--r-- | fs/bcachefs/btree_update.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/bcachefs/btree_update.h b/fs/bcachefs/btree_update.h index 1fd01fb40482..c4aa5e42b29c 100644 --- a/fs/bcachefs/btree_update.h +++ b/fs/bcachefs/btree_update.h @@ -27,6 +27,7 @@ struct btree_insert { struct bch_fs *c; struct disk_reservation *disk_res; struct journal_res journal_res; + struct journal_preres journal_preres; u64 *journal_seq; unsigned flags; bool did_work; @@ -82,6 +83,7 @@ enum { __BTREE_INSERT_USE_RESERVE, __BTREE_INSERT_USE_ALLOC_RESERVE, __BTREE_INSERT_JOURNAL_REPLAY, + __BTREE_INSERT_JOURNAL_RESERVED, __BTREE_INSERT_NOMARK, __BTREE_INSERT_NOWAIT, __BTREE_INSERT_GC_LOCK_HELD, @@ -112,6 +114,8 @@ enum { /* Insert is for journal replay - don't get journal reservations: */ #define BTREE_INSERT_JOURNAL_REPLAY (1 << __BTREE_INSERT_JOURNAL_REPLAY) +#define BTREE_INSERT_JOURNAL_RESERVED (1 << __BTREE_INSERT_JOURNAL_RESERVED) + /* Don't call bch2_mark_key: */ #define BTREE_INSERT_NOMARK (1 << __BTREE_INSERT_NOMARK) |