diff options
author | Hannes Reinecke <hare@suse.de> | 2015-01-08 07:43:47 +0100 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2015-01-09 15:44:31 +0100 |
commit | 026f8da8da4ce3423bf89e8e9091f55ae3863eda (patch) | |
tree | c4a4fef7a66a6ba9d331f3ea2e07b982d935e028 /drivers/scsi/constants.c | |
parent | 2104551969e8011e72788dc5674609d437448cf6 (diff) | |
download | talos-obmc-linux-026f8da8da4ce3423bf89e8e9091f55ae3863eda.tar.gz talos-obmc-linux-026f8da8da4ce3423bf89e8e9091f55ae3863eda.zip |
scsi: use per-cpu buffer for formatting scsi_print_result()
Convert scsi_print_result() to use the per-cpu buffer for decoding the
command result and disposition.
Tested-by: Robert Elliott <elliott@hp.com>
Reviewed-by: Robert Elliott <elliott@hp.com>
Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/constants.c')
-rw-r--r-- | drivers/scsi/constants.c | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/drivers/scsi/constants.c b/drivers/scsi/constants.c index a23ef75533d6..956fbdd38681 100644 --- a/drivers/scsi/constants.c +++ b/drivers/scsi/constants.c @@ -1316,25 +1316,3 @@ const char *scsi_mlreturn_string(int result) return NULL; } EXPORT_SYMBOL(scsi_mlreturn_string); - -void scsi_print_result(struct scsi_cmnd *cmd, const char *msg, int disposition) -{ - const char *mlret_string = scsi_mlreturn_string(disposition); - const char *hb_string = scsi_hostbyte_string(cmd->result); - const char *db_string = scsi_driverbyte_string(cmd->result); - - if (hb_string || db_string) - scmd_printk(KERN_INFO, cmd, - "%s%s Result: hostbyte=%s driverbyte=%s", - msg ? msg : "", - mlret_string ? mlret_string : "UNKNOWN", - hb_string ? hb_string : "invalid", - db_string ? db_string : "invalid"); - else - scmd_printk(KERN_INFO, cmd, - "%s%s Result: hostbyte=0x%02x driverbyte=0x%02x", - msg ? msg : "", - mlret_string ? mlret_string : "UNKNOWN", - host_byte(cmd->result), driver_byte(cmd->result)); -} -EXPORT_SYMBOL(scsi_print_result); |