]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
scsi: qla2xxx: Simplify qlt_lport_dump()
authorBart Van Assche <bvanassche@acm.org>
Fri, 9 Aug 2019 03:01:36 +0000 (20:01 -0700)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 13 Aug 2019 01:34:05 +0000 (21:34 -0400)
Simplify the implementation of this function by using the %phC format
specifier instead of using explicit for-loops.

Cc: Himanshu Madhani <hmadhani@marvell.com>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Tested-by: Himanshu Madhani <hmadhani@marvell.com>
Reviewed-by: Himanshu Madhani <hmadhani@marvell.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/qla2xxx/qla_target.c

index 3a25536c24928aebe99ee52b64e35d8d7abca303..221912da67c6fa40ae264dd6a5865e4b0f305630 100644 (file)
@@ -6497,22 +6497,10 @@ void qlt_remove_target_resources(struct qla_hw_data *ha)
 static void qlt_lport_dump(struct scsi_qla_host *vha, u64 wwpn,
        unsigned char *b)
 {
-       int i;
-
-       pr_debug("qla2xxx HW vha->node_name: ");
-       for (i = 0; i < WWN_SIZE; i++)
-               pr_debug("%02x ", vha->node_name[i]);
-       pr_debug("\n");
-       pr_debug("qla2xxx HW vha->port_name: ");
-       for (i = 0; i < WWN_SIZE; i++)
-               pr_debug("%02x ", vha->port_name[i]);
-       pr_debug("\n");
-
-       pr_debug("qla2xxx passed configfs WWPN: ");
+       pr_debug("qla2xxx HW vha->node_name: %8phC\n", vha->node_name);
+       pr_debug("qla2xxx HW vha->port_name: %8phC\n", vha->port_name);
        put_unaligned_be64(wwpn, b);
-       for (i = 0; i < WWN_SIZE; i++)
-               pr_debug("%02x ", b[i]);
-       pr_debug("\n");
+       pr_debug("qla2xxx passed configfs WWPN: %8phC\n", b);
 }
 
 /**