Skip to content

Commit 7e96d55

Browse files
oferhzshligit
authored andcommitted
md/raid5: add thread_group worker async_tx_issue_pending_all
Since thread_group worker and raid5d kthread are not in sync, if worker writes stripe before raid5d then requests will be waiting for issue_pendig. Issue observed when building raid5 with ext4, in some build runs jbd2 would get hung and requests were waiting in the HW engine waiting to be issued. Fix this by adding a call to async_tx_issue_pending_all in the raid5_do_work. Signed-off-by: Ofer Heifetz <[email protected]> Cc: [email protected] Signed-off-by: Shaohua Li <[email protected]>
1 parent 6308d8e commit 7e96d55

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/md/raid5.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6234,6 +6234,8 @@ static void raid5_do_work(struct work_struct *work)
62346234
pr_debug("%d stripes handled\n", handled);
62356235

62366236
spin_unlock_irq(&conf->device_lock);
6237+
6238+
async_tx_issue_pending_all();
62376239
blk_finish_plug(&plug);
62386240

62396241
pr_debug("--- raid5worker inactive\n");

0 commit comments

Comments
 (0)