mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-04 05:37:36 +00:00
lightnvm: pblk: delete writer kick timer before stopping thread
Unless we delete the timer that wakes up the write thread before we stop the thread we risk re-starting the thread, so delete the timer first. Signed-off-by: Hans Holmberg <hans.holmberg@cnexlabs.com> Reviewed-by: Javier González <javier@cnexlabs.com> Signed-off-by: Matias Bjørling <mb@lightnvm.io> Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
5d149bfabe
commit
7be970b225
1 changed files with 1 additions and 1 deletions
|
@ -912,9 +912,9 @@ static void pblk_writer_stop(struct pblk *pblk)
|
||||||
WARN(pblk_rb_sync_count(&pblk->rwb),
|
WARN(pblk_rb_sync_count(&pblk->rwb),
|
||||||
"Stopping not fully synced write buffer\n");
|
"Stopping not fully synced write buffer\n");
|
||||||
|
|
||||||
|
del_timer_sync(&pblk->wtimer);
|
||||||
if (pblk->writer_ts)
|
if (pblk->writer_ts)
|
||||||
kthread_stop(pblk->writer_ts);
|
kthread_stop(pblk->writer_ts);
|
||||||
del_timer(&pblk->wtimer);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void pblk_free(struct pblk *pblk)
|
static void pblk_free(struct pblk *pblk)
|
||||||
|
|
Loading…
Add table
Reference in a new issue