[SCSI] Print failed commands
authorMartin K. Petersen <martin.petersen@oracle.com>
Sat, 23 May 2009 15:45:07 +0000 (11:45 -0400)
committerJames Bottomley <James.Bottomley@suse.de>
Sat, 22 Aug 2009 22:51:51 +0000 (17:51 -0500)
When a request fails we print the sense data but not the actual command
that failed.  Add a printout of the operation + CDB for failed commands.

Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/scsi_lib.c

index f3c40898fc7d305a9815acccc1e6e366c9f3dd5b..662024d86949fabfe23d7a3ffee2d5fb50590787 100644 (file)
@@ -896,6 +896,7 @@ void scsi_io_completion(struct scsi_cmnd *cmd, unsigned int good_bytes)
                        scsi_print_result(cmd);
                        if (driver_byte(result) & DRIVER_SENSE)
                                scsi_print_sense("", cmd);
+                       scsi_print_command(cmd);
                }
                blk_end_request_all(req, -EIO);
                scsi_next_command(cmd);