diff options
author | Ingo Molnar <mingo@elte.hu> | 2009-04-07 06:05:21 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-04-07 06:05:25 -0400 |
commit | 6c009ecef8cca28c7c09eb16d0802e37915a76e1 (patch) | |
tree | 11c773f780186fdb9fbc9c80a73fb7c8426b1fba /drivers/scsi/scsi_lib.c | |
parent | 98c2aaf8be5baf7193be37fb28bce8e7327158bc (diff) | |
parent | d508afb437daee7cf07da085b635c44a4ebf9b38 (diff) |
Merge branch 'linus' into perfcounters/core
Merge reason: need the upstream facility added by:
7f1e2ca: hrtimer: fix rq->lock inversion (again)
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/scsi/scsi_lib.c')
-rw-r--r-- | drivers/scsi/scsi_lib.c | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 4b13e36d3aa0..d1cb64ad1a3f 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c | |||
@@ -791,7 +791,22 @@ void scsi_io_completion(struct scsi_cmnd *cmd, unsigned int good_bytes) | |||
791 | "%d bytes done.\n", | 791 | "%d bytes done.\n", |
792 | req->nr_sectors, good_bytes)); | 792 | req->nr_sectors, good_bytes)); |
793 | 793 | ||
794 | /* A number of bytes were successfully read. If there | 794 | /* |
795 | * Recovered errors need reporting, but they're always treated | ||
796 | * as success, so fiddle the result code here. For BLOCK_PC | ||
797 | * we already took a copy of the original into rq->errors which | ||
798 | * is what gets returned to the user | ||
799 | */ | ||
800 | if (sense_valid && sshdr.sense_key == RECOVERED_ERROR) { | ||
801 | if (!(req->cmd_flags & REQ_QUIET)) | ||
802 | scsi_print_sense("", cmd); | ||
803 | result = 0; | ||
804 | /* BLOCK_PC may have set error */ | ||
805 | error = 0; | ||
806 | } | ||
807 | |||
808 | /* | ||
809 | * A number of bytes were successfully read. If there | ||
795 | * are leftovers and there is some kind of error | 810 | * are leftovers and there is some kind of error |
796 | * (result != 0), retry the rest. | 811 | * (result != 0), retry the rest. |
797 | */ | 812 | */ |