projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e42951b
)
bcachefs: Fix bch2_bkey_narrow_crcs()
author
Kent Overstreet
<kent.overstreet@gmail.com>
Wed, 21 Aug 2019 22:55:07 +0000
(18:55 -0400)
committer
Kent Overstreet
<kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:08:25 +0000
(17:08 -0400)
We have to reinitialize ptrs whenever we do something that changes them.
Regression from when the code was converted to be generic across all
keys with pointers.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/extents.c
patch
|
blob
|
history
diff --git
a/fs/bcachefs/extents.c
b/fs/bcachefs/extents.c
index 779ee42350ad9e97f5df0bd0b8e55658bb919ba2..f097bed684e5cdbdb11bffffadae47ed799e2350 100644
(file)
--- a/
fs/bcachefs/extents.c
+++ b/
fs/bcachefs/extents.c
@@
-454,6
+454,8
@@
found:
BUG_ON(n.live_size != k->k.size);
restart_narrow_pointers:
+ ptrs = bch2_bkey_ptrs(bkey_i_to_s(k));
+
bkey_for_each_ptr_decode(&k->k, ptrs, p, i)
if (can_narrow_crc(p.crc, n)) {
bch2_bkey_drop_ptr(bkey_i_to_s(k), &i->ptr);