aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/scsi_lib.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index 662024d86949..5987da857103 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -898,8 +898,10 @@ void scsi_io_completion(struct scsi_cmnd *cmd, unsigned int good_bytes)
898 scsi_print_sense("", cmd); 898 scsi_print_sense("", cmd);
899 scsi_print_command(cmd); 899 scsi_print_command(cmd);
900 } 900 }
901 blk_end_request_all(req, -EIO); 901 if (blk_end_request_err(req, -EIO))
902 scsi_next_command(cmd); 902 scsi_requeue_command(q, cmd);
903 else
904 scsi_next_command(cmd);
903 break; 905 break;
904 case ACTION_REPREP: 906 case ACTION_REPREP:
905 /* Unprep the request and put it back at the head of the queue. 907 /* Unprep the request and put it back at the head of the queue.