diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-02-21 19:22:44 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:09:54 -0400 |
commit | c9163bb03b81e465019cf56d2edf47b70798e3ee (patch) | |
tree | fa4e29fa781b97bc47f7038c9d192f210f3b72bb /fs/bcachefs/extents.h | |
parent | e094beccc139b1d2975563cdba0b661d14e6e06b (diff) | |
download | lwn-c9163bb03b81e465019cf56d2edf47b70798e3ee.tar.gz lwn-c9163bb03b81e465019cf56d2edf47b70798e3ee.zip |
bcachefs: Cached pointers should not be erasure coded
There's no reason to erasure code cached pointers: we'll always have
another copy, and it'll be cheaper to read the other copy than do a
reconstruct read. And erasure coded cached pointers would add
complications that we'd rather not have to deal with, so let's make sure
to disallow them.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/extents.h')
-rw-r--r-- | fs/bcachefs/extents.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/bcachefs/extents.h b/fs/bcachefs/extents.h index 1d8f3b309b07..c52a09832857 100644 --- a/fs/bcachefs/extents.h +++ b/fs/bcachefs/extents.h @@ -655,6 +655,8 @@ bool bch2_bkey_matches_ptr(struct bch_fs *, struct bkey_s_c, bool bch2_extents_match(struct bkey_s_c, struct bkey_s_c); bool bch2_extent_has_ptr(struct bkey_s_c, struct extent_ptr_decoded, struct bkey_s_c); +void bch2_extent_ptr_set_cached(struct bkey_s, struct bch_extent_ptr *); + bool bch2_extent_normalize(struct bch_fs *, struct bkey_s); void bch2_bkey_ptrs_to_text(struct printbuf *, struct bch_fs *, struct bkey_s_c); |