mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-14 05:22:19 -04:00
bcachefs: Fix erorr path in bch2_write()
The error path in bch2_write wasn't updated when the end_io callback was added to bch_write_op. Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
committed by
Kent Overstreet
parent
b627c7d8f4
commit
c32bd3ad1f
@@ -1176,7 +1176,12 @@ void bch2_write(struct closure *cl)
|
||||
err:
|
||||
if (!(op->flags & BCH_WRITE_NOPUT_RESERVATION))
|
||||
bch2_disk_reservation_put(c, &op->res);
|
||||
closure_return(cl);
|
||||
if (op->end_io)
|
||||
op->end_io(op);
|
||||
if (cl->parent)
|
||||
closure_return(cl);
|
||||
else
|
||||
closure_debug_destroy(cl);
|
||||
}
|
||||
|
||||
/* Cache promotion on read */
|
||||
|
||||
Reference in New Issue
Block a user