Repository navigation
Commit c53cd18
blk-mq: call commit_rqs while list empty but error happen
[ Upstream commit 632bfb6 ]
Blk-mq should call commit_rqs once 'bd.last != true' and no more
request will come(so virtscsi can kick the virtqueue, e.g.). We already
do that in 'blk_mq_dispatch_rq_list/blk_mq_try_issue_list_directly' while
list not empty and 'queued > 0'. However, we can seen the same scene
once the last request in list call queue_rq and return error like
BLK_STS_IOERR which will not requeue the request, and lead that list
empty but need call commit_rqs too(Or the request for virtscsi will stay
timeout until other request kick virtqueue).
We found this problem by do fsstress test with offline/online virtscsi
device repeat quickly.
Fixes: d666ba9 ("blk-mq: add mq_ops->commit_rqs()")
Reported-by: zhangyi (F) <yi.zhang@huawei.com>
Signed-off-by: yangerkun <yangerkun@huawei.com>
Reviewed-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent a6141f1 commit c53cd18
1 file changed
Lines changed: 9 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1304 | 1304 | | |
1305 | 1305 | | |
1306 | 1306 | | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
1307 | 1312 | | |
1308 | 1313 | | |
1309 | 1314 | | |
1310 | 1315 | | |
1311 | 1316 | | |
1312 | 1317 | | |
1313 | 1318 | | |
1314 | | - | |
1315 | | - | |
1316 | | - | |
1317 | | - | |
1318 | | - | |
1319 | | - | |
1320 | | - | |
1321 | | - | |
1322 | 1319 | | |
1323 | 1320 | | |
1324 | 1321 | | |
| |||
1971 | 1968 | | |
1972 | 1969 | | |
1973 | 1970 | | |
| 1971 | + | |
1974 | 1972 | | |
1975 | 1973 | | |
1976 | 1974 | | |
| |||
1987 | 1985 | | |
1988 | 1986 | | |
1989 | 1987 | | |
| 1988 | + | |
1990 | 1989 | | |
1991 | 1990 | | |
1992 | 1991 | | |
| |||
1996 | 1995 | | |
1997 | 1996 | | |
1998 | 1997 | | |
1999 | | - | |
| 1998 | + | |
| 1999 | + | |
2000 | 2000 | | |
2001 | 2001 | | |
2002 | 2002 | | |
| |||
0 commit comments