scsi: set timed out out mq requests to complete
authorKeith Busch <keith.busch@intel.com>
Mon, 23 Jul 2018 14:37:51 +0000 (08:37 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 24 Jul 2018 20:41:52 +0000 (14:41 -0600)
commit065990bd198e0e67417c2c34e5e80140d4b8cef7
tree599953a4f653a4091f05074bb7e7cfa94cac2a9b
parent0fc09f920983f61be625658c62cc40ac25a7b3a5
scsi: set timed out out mq requests to complete

The scsi block layer requires requests claimed by the error handling be
completed by the error handler. A previous commit allowed completions
to proceed for blk-mq, breaking that assumption.

This patch prevents completions that may race with the timeout handler
by marking the state to complete, restoring the previous behavior.

Fixes: 12f5b931 ("blk-mq: Remove generation seqeunce")
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <keith.busch@intel.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/scsi/scsi_error.c