projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
793a06d
)
bcachefs: nocow locking: Fix lock leak
author
Kent Overstreet
<kent.overstreet@linux.dev>
Mon, 25 Sep 2023 01:05:50 +0000
(21:05 -0400)
committer
Kent Overstreet
<kent.overstreet@linux.dev>
Sun, 22 Oct 2023 21:10:15 +0000
(17:10 -0400)
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
fs/bcachefs/io_write.c
patch
|
blob
|
history
diff --git
a/fs/bcachefs/io_write.c
b/fs/bcachefs/io_write.c
index
d2a0de8
..
6e4f85e
100644
(file)
--- a/
fs/bcachefs/io_write.c
+++ b/
fs/bcachefs/io_write.c
@@
-1376,10
+1376,12
@@
err_get_ioref:
/* Fall back to COW path: */
goto out;
err_bucket_stale:
- while (
--i >= 0)
+ while (
i >= 0) {
bch2_bucket_nocow_unlock(&c->nocow_locks,
buckets[i].b,
BUCKET_NOCOW_LOCK_UPDATE);
+ --i;
+ }
for (i = 0; i < nr_buckets; i++)
percpu_ref_put(&bch_dev_bkey_exists(c, buckets[i].b.inode)->io_ref);