projects
/
linux-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d7dd3fb
)
bcachefs: Check for lru entries with time=0
author
Kent Overstreet
<kent.overstreet@linux.dev>
Wed, 4 Jan 2023 05:00:55 +0000
(
00:00
-0500)
committer
Kent Overstreet
<kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:09:49 +0000
(17:09 -0400)
These are invalid.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/lru.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/bcachefs/lru.c
b/fs/bcachefs/lru.c
index e16686b3b45aa00d018c068de1bb30a84b92ec43..9b4ce27d12f3094802db0e7f9aa42e008202a0fa 100644
(file)
--- a/
fs/bcachefs/lru.c
+++ b/
fs/bcachefs/lru.c
@@
-19,6
+19,12
@@
int bch2_lru_invalid(const struct bch_fs *c, struct bkey_s_c k,
return -BCH_ERR_invalid_bkey;
}
+ if (!k.k->p.offset) {
+ prt_printf(err, "lru entry at time=0");
+ return -BCH_ERR_invalid_bkey;
+
+ }
+
return 0;
}