diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2019-01-24 16:50:48 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:08:15 -0400 |
commit | eac3ca0f49737ba3120ccaa990877b2a05bc88cc (patch) | |
tree | 3cc6fda61ffd4f2ac6984c5bebfbdfdd8332baf0 /fs/bcachefs/journal_types.h | |
parent | 6e1b07183a32583cbe4d781ea0e14e0b06bc44af (diff) | |
download | linux-eac3ca0f49737ba3120ccaa990877b2a05bc88cc.tar.gz linux-eac3ca0f49737ba3120ccaa990877b2a05bc88cc.tar.bz2 linux-eac3ca0f49737ba3120ccaa990877b2a05bc88cc.zip |
bcachefs: New journal_entry_res mechanism
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/journal_types.h')
-rw-r--r-- | fs/bcachefs/journal_types.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/fs/bcachefs/journal_types.h b/fs/bcachefs/journal_types.h index 51e453652d67..5f6d2320c5cd 100644 --- a/fs/bcachefs/journal_types.h +++ b/fs/bcachefs/journal_types.h @@ -24,6 +24,7 @@ struct journal_buf { unsigned size; unsigned disk_sectors; + unsigned u64s_reserved; /* bloom filter: */ unsigned long has_inode[1024 / sizeof(unsigned long)]; }; @@ -155,6 +156,9 @@ struct journal { u64 seq_ondisk; u64 last_seq_ondisk; + /* Reserved space in journal entry to be used just prior to write */ + unsigned entry_u64s_reserved; + /* * FIFO of journal entries whose btree updates have not yet been * written out. @@ -243,4 +247,11 @@ struct journal_device { struct closure read; }; +/* + * journal_entry_res - reserve space in every journal entry: + */ +struct journal_entry_res { + unsigned u64s; +}; + #endif /* _BCACHEFS_JOURNAL_TYPES_H */ |