diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-03-14 11:48:07 -0400 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-05-12 19:42:30 -0400 |
commit | 1ebd022dce1e06a6ab05d974b15ad4f51897f8da (patch) | |
tree | ce88a72ffc4b3add30ddab74d0f0b5a1cc36fff1 | |
parent | 83e898c2e03299ab27ab0be1b29b77dee9728113 (diff) |
bcachefs: Fix an assert in copygc thread shutdown path
We're not supposed to have nested (locked) btree_trans on the stack:
this means copygc shutdown needs to exit our btree_trans before exiting
the move_ctxt, which calls bch2_write().
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
-rw-r--r-- | fs/bcachefs/movinggc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/bcachefs/movinggc.c b/fs/bcachefs/movinggc.c index 4d8d013fe4fc..4762594f6287 100644 --- a/fs/bcachefs/movinggc.c +++ b/fs/bcachefs/movinggc.c @@ -334,8 +334,8 @@ static int bch2_copygc_thread(void *arg) wake_up(&c->copygc_running_wq); } - bch2_moving_ctxt_exit(&ctxt); bch2_trans_exit(&trans); + bch2_moving_ctxt_exit(&ctxt); free_fifo(&move_buckets); return 0; |