diff options
author | Tyrel Datwyler <tyreld@linux.vnet.ibm.com> | 2016-02-11 16:24:35 -0600 |
---|---|---|
committer | Martin K. Petersen <martin.petersen@oracle.com> | 2016-02-23 21:27:02 -0500 |
commit | 21367e2027b47b7802388e1b6a672e985d87c442 (patch) | |
tree | d7f2ec04919936c4a7bb36181877b84749cce377 /drivers/scsi/ibmvscsi | |
parent | 06cdbeffe531a6164a5e75951a083128c0fe593d (diff) | |
download | linux-stable-21367e2027b47b7802388e1b6a672e985d87c442.tar.gz linux-stable-21367e2027b47b7802388e1b6a672e985d87c442.tar.bz2 linux-stable-21367e2027b47b7802388e1b6a672e985d87c442.zip |
ibmvfc: byteswap scsi_id, wwpn, and node_name prior to logging
When logging async events the scsi_id, wwpn, and node_name values are
used directly from the CRQ struct which are of type __be64. This can be
confusing to someone looking through the log on a LE system. Instead
byteswap these values to host endian prior to logging.
Signed-off-by: Tyrel Datwyler <tyreld@linux.vnet.ibm.com>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/ibmvscsi')
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvfc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c index 6aa317c303e2..fc523c3e5019 100644 --- a/drivers/scsi/ibmvscsi/ibmvfc.c +++ b/drivers/scsi/ibmvscsi/ibmvfc.c @@ -2636,7 +2636,8 @@ static void ibmvfc_handle_async(struct ibmvfc_async_crq *crq, struct ibmvfc_target *tgt; ibmvfc_log(vhost, desc->log_level, "%s event received. scsi_id: %llx, wwpn: %llx," - " node_name: %llx%s\n", desc->desc, crq->scsi_id, crq->wwpn, crq->node_name, + " node_name: %llx%s\n", desc->desc, be64_to_cpu(crq->scsi_id), + be64_to_cpu(crq->wwpn), be64_to_cpu(crq->node_name), ibmvfc_get_link_state(crq->link_state)); switch (be64_to_cpu(crq->event)) { |