aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
authorHannes Reinecke <hare@suse.de>2014-06-25 09:27:36 -0400
committerChristoph Hellwig <hch@lst.de>2014-07-17 16:07:37 -0400
commit9cb78c16f5dadefd8dc5ba0ae5a2f26cd59419b3 (patch)
tree576b86c3ec56dd7176285ec2d27f27ca55f77bc3 /drivers/scsi/qla2xxx
parent755f516bbb983915d6cbfb5aa592cc0a5a99fd00 (diff)
scsi: use 64-bit LUNs
The SCSI standard defines 64-bit values for LUNs, and large arrays employing large or hierarchical LUN numbers become more and more common. So update the linux SCSI stack to use 64-bit LUN numbers. Signed-off-by: Hannes Reinecke <hare@suse.de> Reviewed-by: Christoph Hellwig <hch@infradead.org> Reviewed-by: Ewan Milne <emilne@redhat.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_def.h6
-rw-r--r--drivers/scsi/qla2xxx/qla_gbl.h16
-rw-r--r--drivers/scsi/qla2xxx/qla_iocb.c11
-rw-r--r--drivers/scsi/qla2xxx/qla_isr.c4
-rw-r--r--drivers/scsi/qla2xxx/qla_mbx.c12
-rw-r--r--drivers/scsi/qla2xxx/qla_mr.c8
-rw-r--r--drivers/scsi/qla2xxx/qla_os.c35
7 files changed, 47 insertions, 45 deletions
diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h
index de5d0ae19d83..b64399153135 100644
--- a/drivers/scsi/qla2xxx/qla_def.h
+++ b/drivers/scsi/qla2xxx/qla_def.h
@@ -320,8 +320,8 @@ struct srb_iocb {
320 * defined in tsk_mgmt_entry struct 320 * defined in tsk_mgmt_entry struct
321 * for control_flags field in qla_fw.h. 321 * for control_flags field in qla_fw.h.
322 */ 322 */
323 uint64_t lun;
323 uint32_t flags; 324 uint32_t flags;
324 uint32_t lun;
325 uint32_t data; 325 uint32_t data;
326 struct completion comp; 326 struct completion comp;
327 __le16 comp_status; 327 __le16 comp_status;
@@ -2529,8 +2529,8 @@ struct isp_operations {
2529 void (*disable_intrs) (struct qla_hw_data *); 2529 void (*disable_intrs) (struct qla_hw_data *);
2530 2530
2531 int (*abort_command) (srb_t *); 2531 int (*abort_command) (srb_t *);
2532 int (*target_reset) (struct fc_port *, unsigned int, int); 2532 int (*target_reset) (struct fc_port *, uint64_t, int);
2533 int (*lun_reset) (struct fc_port *, unsigned int, int); 2533 int (*lun_reset) (struct fc_port *, uint64_t, int);
2534 int (*fabric_login) (struct scsi_qla_host *, uint16_t, uint8_t, 2534 int (*fabric_login) (struct scsi_qla_host *, uint16_t, uint8_t,
2535 uint8_t, uint8_t, uint16_t *, uint8_t); 2535 uint8_t, uint8_t, uint16_t *, uint8_t);
2536 int (*fabric_logout) (struct scsi_qla_host *, uint16_t, uint8_t, 2536 int (*fabric_logout) (struct scsi_qla_host *, uint16_t, uint8_t,
diff --git a/drivers/scsi/qla2xxx/qla_gbl.h b/drivers/scsi/qla2xxx/qla_gbl.h
index d48dea8fab1b..9ef0781b12da 100644
--- a/drivers/scsi/qla2xxx/qla_gbl.h
+++ b/drivers/scsi/qla2xxx/qla_gbl.h
@@ -212,7 +212,7 @@ extern void qla2x00_build_scsi_iocbs_64(srb_t *, cmd_entry_t *, uint16_t);
212extern int qla2x00_start_scsi(srb_t *sp); 212extern int qla2x00_start_scsi(srb_t *sp);
213extern int qla24xx_start_scsi(srb_t *sp); 213extern int qla24xx_start_scsi(srb_t *sp);
214int qla2x00_marker(struct scsi_qla_host *, struct req_que *, struct rsp_que *, 214int qla2x00_marker(struct scsi_qla_host *, struct req_que *, struct rsp_que *,
215 uint16_t, uint16_t, uint8_t); 215 uint16_t, uint64_t, uint8_t);
216extern int qla2x00_start_sp(srb_t *); 216extern int qla2x00_start_sp(srb_t *);
217extern int qla24xx_dif_start_scsi(srb_t *); 217extern int qla24xx_dif_start_scsi(srb_t *);
218extern int qla2x00_start_bidir(srb_t *, struct scsi_qla_host *, uint32_t); 218extern int qla2x00_start_bidir(srb_t *, struct scsi_qla_host *, uint32_t);
@@ -262,10 +262,10 @@ extern int
262qla2x00_abort_command(srb_t *); 262qla2x00_abort_command(srb_t *);
263 263
264extern int 264extern int
265qla2x00_abort_target(struct fc_port *, unsigned int, int); 265qla2x00_abort_target(struct fc_port *, uint64_t, int);
266 266
267extern int 267extern int
268qla2x00_lun_reset(struct fc_port *, unsigned int, int); 268qla2x00_lun_reset(struct fc_port *, uint64_t, int);
269 269
270extern int 270extern int
271qla2x00_get_adapter_id(scsi_qla_host_t *, uint16_t *, uint8_t *, uint8_t *, 271qla2x00_get_adapter_id(scsi_qla_host_t *, uint16_t *, uint8_t *, uint8_t *,
@@ -339,12 +339,12 @@ qla24xx_get_isp_stats(scsi_qla_host_t *, struct link_statistics *,
339extern int qla24xx_abort_command(srb_t *); 339extern int qla24xx_abort_command(srb_t *);
340extern int qla24xx_async_abort_command(srb_t *); 340extern int qla24xx_async_abort_command(srb_t *);
341extern int 341extern int
342qla24xx_abort_target(struct fc_port *, unsigned int, int); 342qla24xx_abort_target(struct fc_port *, uint64_t, int);
343extern int 343extern int
344qla24xx_lun_reset(struct fc_port *, unsigned int, int); 344qla24xx_lun_reset(struct fc_port *, uint64_t, int);
345extern int 345extern int
346qla2x00_eh_wait_for_pending_commands(scsi_qla_host_t *, unsigned int, 346qla2x00_eh_wait_for_pending_commands(scsi_qla_host_t *, unsigned int,
347 unsigned int, enum nexus_wait_type); 347 uint64_t, enum nexus_wait_type);
348extern int 348extern int
349qla2x00_system_error(scsi_qla_host_t *); 349qla2x00_system_error(scsi_qla_host_t *);
350 350
@@ -617,8 +617,8 @@ extern char *qlafx00_fw_version_str(struct scsi_qla_host *, char *);
617extern irqreturn_t qlafx00_intr_handler(int, void *); 617extern irqreturn_t qlafx00_intr_handler(int, void *);
618extern void qlafx00_enable_intrs(struct qla_hw_data *); 618extern void qlafx00_enable_intrs(struct qla_hw_data *);
619extern void qlafx00_disable_intrs(struct qla_hw_data *); 619extern void qlafx00_disable_intrs(struct qla_hw_data *);
620extern int qlafx00_abort_target(fc_port_t *, unsigned int, int); 620extern int qlafx00_abort_target(fc_port_t *, uint64_t, int);
621extern int qlafx00_lun_reset(fc_port_t *, unsigned int, int); 621extern int qlafx00_lun_reset(fc_port_t *, uint64_t, int);
622extern int qlafx00_start_scsi(srb_t *); 622extern int qlafx00_start_scsi(srb_t *);
623extern int qlafx00_abort_isp(scsi_qla_host_t *); 623extern int qlafx00_abort_isp(scsi_qla_host_t *);
624extern int qlafx00_iospace_config(struct qla_hw_data *); 624extern int qlafx00_iospace_config(struct qla_hw_data *);
diff --git a/drivers/scsi/qla2xxx/qla_iocb.c b/drivers/scsi/qla2xxx/qla_iocb.c
index 760931529592..150529d98db4 100644
--- a/drivers/scsi/qla2xxx/qla_iocb.c
+++ b/drivers/scsi/qla2xxx/qla_iocb.c
@@ -520,7 +520,7 @@ qla2x00_start_iocbs(struct scsi_qla_host *vha, struct req_que *req)
520static int 520static int
521__qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req, 521__qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req,
522 struct rsp_que *rsp, uint16_t loop_id, 522 struct rsp_que *rsp, uint16_t loop_id,
523 uint16_t lun, uint8_t type) 523 uint64_t lun, uint8_t type)
524{ 524{
525 mrk_entry_t *mrk; 525 mrk_entry_t *mrk;
526 struct mrk_entry_24xx *mrk24 = NULL; 526 struct mrk_entry_24xx *mrk24 = NULL;
@@ -543,14 +543,13 @@ __qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req,
543 if (IS_FWI2_CAPABLE(ha)) { 543 if (IS_FWI2_CAPABLE(ha)) {
544 mrk24 = (struct mrk_entry_24xx *) mrk; 544 mrk24 = (struct mrk_entry_24xx *) mrk;
545 mrk24->nport_handle = cpu_to_le16(loop_id); 545 mrk24->nport_handle = cpu_to_le16(loop_id);
546 mrk24->lun[1] = LSB(lun); 546 int_to_scsilun(lun, (struct scsi_lun *)&mrk24->lun);
547 mrk24->lun[2] = MSB(lun);
548 host_to_fcp_swap(mrk24->lun, sizeof(mrk24->lun)); 547 host_to_fcp_swap(mrk24->lun, sizeof(mrk24->lun));
549 mrk24->vp_index = vha->vp_idx; 548 mrk24->vp_index = vha->vp_idx;
550 mrk24->handle = MAKE_HANDLE(req->id, mrk24->handle); 549 mrk24->handle = MAKE_HANDLE(req->id, mrk24->handle);
551 } else { 550 } else {
552 SET_TARGET_ID(ha, mrk->target, loop_id); 551 SET_TARGET_ID(ha, mrk->target, loop_id);
553 mrk->lun = cpu_to_le16(lun); 552 mrk->lun = cpu_to_le16((uint16_t)lun);
554 } 553 }
555 } 554 }
556 wmb(); 555 wmb();
@@ -562,7 +561,7 @@ __qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req,
562 561
563int 562int
564qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req, 563qla2x00_marker(struct scsi_qla_host *vha, struct req_que *req,
565 struct rsp_que *rsp, uint16_t loop_id, uint16_t lun, 564 struct rsp_que *rsp, uint16_t loop_id, uint64_t lun,
566 uint8_t type) 565 uint8_t type)
567{ 566{
568 int ret; 567 int ret;
@@ -2047,7 +2046,7 @@ static void
2047qla24xx_tm_iocb(srb_t *sp, struct tsk_mgmt_entry *tsk) 2046qla24xx_tm_iocb(srb_t *sp, struct tsk_mgmt_entry *tsk)
2048{ 2047{
2049 uint32_t flags; 2048 uint32_t flags;
2050 unsigned int lun; 2049 uint64_t lun;
2051 struct fc_port *fcport = sp->fcport; 2050 struct fc_port *fcport = sp->fcport;
2052 scsi_qla_host_t *vha = fcport->vha; 2051 scsi_qla_host_t *vha = fcport->vha;
2053 struct qla_hw_data *ha = vha->hw; 2052 struct qla_hw_data *ha = vha->hw;
diff --git a/drivers/scsi/qla2xxx/qla_isr.c b/drivers/scsi/qla2xxx/qla_isr.c
index a56825c73c31..550a4a31f51a 100644
--- a/drivers/scsi/qla2xxx/qla_isr.c
+++ b/drivers/scsi/qla2xxx/qla_isr.c
@@ -1659,7 +1659,7 @@ qla2x00_handle_sense(srb_t *sp, uint8_t *sense_data, uint32_t par_sense_len,
1659 1659
1660 if (sense_len) { 1660 if (sense_len) {
1661 ql_dbg(ql_dbg_io + ql_dbg_buffer, vha, 0x301c, 1661 ql_dbg(ql_dbg_io + ql_dbg_buffer, vha, 0x301c,
1662 "Check condition Sense data, nexus%ld:%d:%d cmd=%p.\n", 1662 "Check condition Sense data, nexus%ld:%d:%llu cmd=%p.\n",
1663 sp->fcport->vha->host_no, cp->device->id, cp->device->lun, 1663 sp->fcport->vha->host_no, cp->device->id, cp->device->lun,
1664 cp); 1664 cp);
1665 ql_dump_buffer(ql_dbg_io + ql_dbg_buffer, vha, 0x302b, 1665 ql_dump_buffer(ql_dbg_io + ql_dbg_buffer, vha, 0x302b,
@@ -2281,7 +2281,7 @@ check_scsi_status:
2281out: 2281out:
2282 if (logit) 2282 if (logit)
2283 ql_dbg(ql_dbg_io, fcport->vha, 0x3022, 2283 ql_dbg(ql_dbg_io, fcport->vha, 0x3022,
2284 "FCP command status: 0x%x-0x%x (0x%x) nexus=%ld:%d:%d " 2284 "FCP command status: 0x%x-0x%x (0x%x) nexus=%ld:%d:%llu "
2285 "portid=%02x%02x%02x oxid=0x%x cdb=%10phN len=0x%x " 2285 "portid=%02x%02x%02x oxid=0x%x cdb=%10phN len=0x%x "
2286 "rsp_info=0x%x resid=0x%x fw_resid=0x%x.\n", 2286 "rsp_info=0x%x resid=0x%x fw_resid=0x%x.\n",
2287 comp_status, scsi_status, res, vha->host_no, 2287 comp_status, scsi_status, res, vha->host_no,
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 1c33a77db5c2..d9aafc003be2 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -947,7 +947,7 @@ qla2x00_abort_command(srb_t *sp)
947} 947}
948 948
949int 949int
950qla2x00_abort_target(struct fc_port *fcport, unsigned int l, int tag) 950qla2x00_abort_target(struct fc_port *fcport, uint64_t l, int tag)
951{ 951{
952 int rval, rval2; 952 int rval, rval2;
953 mbx_cmd_t mc; 953 mbx_cmd_t mc;
@@ -1000,7 +1000,7 @@ qla2x00_abort_target(struct fc_port *fcport, unsigned int l, int tag)
1000} 1000}
1001 1001
1002int 1002int
1003qla2x00_lun_reset(struct fc_port *fcport, unsigned int l, int tag) 1003qla2x00_lun_reset(struct fc_port *fcport, uint64_t l, int tag)
1004{ 1004{
1005 int rval, rval2; 1005 int rval, rval2;
1006 mbx_cmd_t mc; 1006 mbx_cmd_t mc;
@@ -1022,7 +1022,7 @@ qla2x00_lun_reset(struct fc_port *fcport, unsigned int l, int tag)
1022 mcp->mb[1] = fcport->loop_id; 1022 mcp->mb[1] = fcport->loop_id;
1023 else 1023 else
1024 mcp->mb[1] = fcport->loop_id << 8; 1024 mcp->mb[1] = fcport->loop_id << 8;
1025 mcp->mb[2] = l; 1025 mcp->mb[2] = (u32)l;
1026 mcp->mb[3] = 0; 1026 mcp->mb[3] = 0;
1027 mcp->mb[9] = vha->vp_idx; 1027 mcp->mb[9] = vha->vp_idx;
1028 1028
@@ -2666,7 +2666,7 @@ struct tsk_mgmt_cmd {
2666 2666
2667static int 2667static int
2668__qla24xx_issue_tmf(char *name, uint32_t type, struct fc_port *fcport, 2668__qla24xx_issue_tmf(char *name, uint32_t type, struct fc_port *fcport,
2669 unsigned int l, int tag) 2669 uint64_t l, int tag)
2670{ 2670{
2671 int rval, rval2; 2671 int rval, rval2;
2672 struct tsk_mgmt_cmd *tsk; 2672 struct tsk_mgmt_cmd *tsk;
@@ -2760,7 +2760,7 @@ __qla24xx_issue_tmf(char *name, uint32_t type, struct fc_port *fcport,
2760} 2760}
2761 2761
2762int 2762int
2763qla24xx_abort_target(struct fc_port *fcport, unsigned int l, int tag) 2763qla24xx_abort_target(struct fc_port *fcport, uint64_t l, int tag)
2764{ 2764{
2765 struct qla_hw_data *ha = fcport->vha->hw; 2765 struct qla_hw_data *ha = fcport->vha->hw;
2766 2766
@@ -2771,7 +2771,7 @@ qla24xx_abort_target(struct fc_port *fcport, unsigned int l, int tag)
2771} 2771}
2772 2772
2773int 2773int
2774qla24xx_lun_reset(struct fc_port *fcport, unsigned int l, int tag) 2774qla24xx_lun_reset(struct fc_port *fcport, uint64_t l, int tag)
2775{ 2775{
2776 struct qla_hw_data *ha = fcport->vha->hw; 2776 struct qla_hw_data *ha = fcport->vha->hw;
2777 2777
diff --git a/drivers/scsi/qla2xxx/qla_mr.c b/drivers/scsi/qla2xxx/qla_mr.c
index abeb3901498b..4775baa8b6a0 100644
--- a/drivers/scsi/qla2xxx/qla_mr.c
+++ b/drivers/scsi/qla2xxx/qla_mr.c
@@ -726,13 +726,13 @@ qlafx00_disable_intrs(struct qla_hw_data *ha)
726} 726}
727 727
728int 728int
729qlafx00_abort_target(fc_port_t *fcport, unsigned int l, int tag) 729qlafx00_abort_target(fc_port_t *fcport, uint64_t l, int tag)
730{ 730{
731 return qla2x00_async_tm_cmd(fcport, TCF_TARGET_RESET, l, tag); 731 return qla2x00_async_tm_cmd(fcport, TCF_TARGET_RESET, l, tag);
732} 732}
733 733
734int 734int
735qlafx00_lun_reset(fc_port_t *fcport, unsigned int l, int tag) 735qlafx00_lun_reset(fc_port_t *fcport, uint64_t l, int tag)
736{ 736{
737 return qla2x00_async_tm_cmd(fcport, TCF_LUN_RESET, l, tag); 737 return qla2x00_async_tm_cmd(fcport, TCF_LUN_RESET, l, tag);
738} 738}
@@ -2159,7 +2159,7 @@ qlafx00_handle_sense(srb_t *sp, uint8_t *sense_data, uint32_t par_sense_len,
2159 2159
2160 if (sense_len) { 2160 if (sense_len) {
2161 ql_dbg(ql_dbg_io + ql_dbg_buffer, vha, 0x3039, 2161 ql_dbg(ql_dbg_io + ql_dbg_buffer, vha, 0x3039,
2162 "Check condition Sense data, nexus%ld:%d:%d cmd=%p.\n", 2162 "Check condition Sense data, nexus%ld:%d:%llu cmd=%p.\n",
2163 sp->fcport->vha->host_no, cp->device->id, cp->device->lun, 2163 sp->fcport->vha->host_no, cp->device->id, cp->device->lun,
2164 cp); 2164 cp);
2165 ql_dump_buffer(ql_dbg_io + ql_dbg_buffer, vha, 0x3049, 2165 ql_dump_buffer(ql_dbg_io + ql_dbg_buffer, vha, 0x3049,
@@ -2524,7 +2524,7 @@ check_scsi_status:
2524 2524
2525 if (logit) 2525 if (logit)
2526 ql_dbg(ql_dbg_io, fcport->vha, 0x3058, 2526 ql_dbg(ql_dbg_io, fcport->vha, 0x3058,
2527 "FCP command status: 0x%x-0x%x (0x%x) nexus=%ld:%d:%d " 2527 "FCP command status: 0x%x-0x%x (0x%x) nexus=%ld:%d:%llu "
2528 "tgt_id: 0x%x lscsi_status: 0x%x cdb=%10phN len=0x%x " 2528 "tgt_id: 0x%x lscsi_status: 0x%x cdb=%10phN len=0x%x "
2529 "rsp_info=0x%x resid=0x%x fw_resid=0x%x sense_len=0x%x, " 2529 "rsp_info=0x%x resid=0x%x fw_resid=0x%x sense_len=0x%x, "
2530 "par_sense_len=0x%x, rsp_info_len=0x%x\n", 2530 "par_sense_len=0x%x, rsp_info_len=0x%x\n",
diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 5269aee1df3b..b22c75305b44 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -920,7 +920,8 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
920 scsi_qla_host_t *vha = shost_priv(cmd->device->host); 920 scsi_qla_host_t *vha = shost_priv(cmd->device->host);
921 srb_t *sp; 921 srb_t *sp;
922 int ret; 922 int ret;
923 unsigned int id, lun; 923 unsigned int id;
924 uint64_t lun;
924 unsigned long flags; 925 unsigned long flags;
925 int rval, wait = 0; 926 int rval, wait = 0;
926 struct qla_hw_data *ha = vha->hw; 927 struct qla_hw_data *ha = vha->hw;
@@ -944,7 +945,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
944 } 945 }
945 946
946 ql_dbg(ql_dbg_taskm, vha, 0x8002, 947 ql_dbg(ql_dbg_taskm, vha, 0x8002,
947 "Aborting from RISC nexus=%ld:%d:%d sp=%p cmd=%p\n", 948 "Aborting from RISC nexus=%ld:%d:%llu sp=%p cmd=%p\n",
948 vha->host_no, id, lun, sp, cmd); 949 vha->host_no, id, lun, sp, cmd);
949 950
950 /* Get a reference to the sp and drop the lock.*/ 951 /* Get a reference to the sp and drop the lock.*/
@@ -995,7 +996,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
995 } 996 }
996 997
997 ql_log(ql_log_info, vha, 0x801c, 998 ql_log(ql_log_info, vha, 0x801c,
998 "Abort command issued nexus=%ld:%d:%d -- %d %x.\n", 999 "Abort command issued nexus=%ld:%d:%llu -- %d %x.\n",
999 vha->host_no, id, lun, wait, ret); 1000 vha->host_no, id, lun, wait, ret);
1000 1001
1001 return ret; 1002 return ret;
@@ -1003,7 +1004,7 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)
1003 1004
1004int 1005int
1005qla2x00_eh_wait_for_pending_commands(scsi_qla_host_t *vha, unsigned int t, 1006qla2x00_eh_wait_for_pending_commands(scsi_qla_host_t *vha, unsigned int t,
1006 unsigned int l, enum nexus_wait_type type) 1007 uint64_t l, enum nexus_wait_type type)
1007{ 1008{
1008 int cnt, match, status; 1009 int cnt, match, status;
1009 unsigned long flags; 1010 unsigned long flags;
@@ -1060,7 +1061,7 @@ static char *reset_errors[] = {
1060 1061
1061static int 1062static int
1062__qla2xxx_eh_generic_reset(char *name, enum nexus_wait_type type, 1063__qla2xxx_eh_generic_reset(char *name, enum nexus_wait_type type,
1063 struct scsi_cmnd *cmd, int (*do_reset)(struct fc_port *, unsigned int, int)) 1064 struct scsi_cmnd *cmd, int (*do_reset)(struct fc_port *, uint64_t, int))
1064{ 1065{
1065 scsi_qla_host_t *vha = shost_priv(cmd->device->host); 1066 scsi_qla_host_t *vha = shost_priv(cmd->device->host);
1066 fc_port_t *fcport = (struct fc_port *) cmd->device->hostdata; 1067 fc_port_t *fcport = (struct fc_port *) cmd->device->hostdata;
@@ -1075,7 +1076,7 @@ __qla2xxx_eh_generic_reset(char *name, enum nexus_wait_type type,
1075 return err; 1076 return err;
1076 1077
1077 ql_log(ql_log_info, vha, 0x8009, 1078 ql_log(ql_log_info, vha, 0x8009,
1078 "%s RESET ISSUED nexus=%ld:%d:%d cmd=%p.\n", name, vha->host_no, 1079 "%s RESET ISSUED nexus=%ld:%d:%llu cmd=%p.\n", name, vha->host_no,
1079 cmd->device->id, cmd->device->lun, cmd); 1080 cmd->device->id, cmd->device->lun, cmd);
1080 1081
1081 err = 0; 1082 err = 0;
@@ -1100,14 +1101,14 @@ __qla2xxx_eh_generic_reset(char *name, enum nexus_wait_type type,
1100 } 1101 }
1101 1102
1102 ql_log(ql_log_info, vha, 0x800e, 1103 ql_log(ql_log_info, vha, 0x800e,
1103 "%s RESET SUCCEEDED nexus:%ld:%d:%d cmd=%p.\n", name, 1104 "%s RESET SUCCEEDED nexus:%ld:%d:%llu cmd=%p.\n", name,
1104 vha->host_no, cmd->device->id, cmd->device->lun, cmd); 1105 vha->host_no, cmd->device->id, cmd->device->lun, cmd);
1105 1106
1106 return SUCCESS; 1107 return SUCCESS;
1107 1108
1108eh_reset_failed: 1109eh_reset_failed:
1109 ql_log(ql_log_info, vha, 0x800f, 1110 ql_log(ql_log_info, vha, 0x800f,
1110 "%s RESET FAILED: %s nexus=%ld:%d:%d cmd=%p.\n", name, 1111 "%s RESET FAILED: %s nexus=%ld:%d:%llu cmd=%p.\n", name,
1111 reset_errors[err], vha->host_no, cmd->device->id, cmd->device->lun, 1112 reset_errors[err], vha->host_no, cmd->device->id, cmd->device->lun,
1112 cmd); 1113 cmd);
1113 return FAILED; 1114 return FAILED;
@@ -1154,7 +1155,8 @@ qla2xxx_eh_bus_reset(struct scsi_cmnd *cmd)
1154 scsi_qla_host_t *vha = shost_priv(cmd->device->host); 1155 scsi_qla_host_t *vha = shost_priv(cmd->device->host);
1155 fc_port_t *fcport = (struct fc_port *) cmd->device->hostdata; 1156 fc_port_t *fcport = (struct fc_port *) cmd->device->hostdata;
1156 int ret = FAILED; 1157 int ret = FAILED;
1157 unsigned int id, lun; 1158 unsigned int id;
1159 uint64_t lun;
1158 1160
1159 id = cmd->device->id; 1161 id = cmd->device->id;
1160 lun = cmd->device->lun; 1162 lun = cmd->device->lun;
@@ -1169,7 +1171,7 @@ qla2xxx_eh_bus_reset(struct scsi_cmnd *cmd)
1169 ret = FAILED; 1171 ret = FAILED;
1170 1172
1171 ql_log(ql_log_info, vha, 0x8012, 1173 ql_log(ql_log_info, vha, 0x8012,
1172 "BUS RESET ISSUED nexus=%ld:%d:%d.\n", vha->host_no, id, lun); 1174 "BUS RESET ISSUED nexus=%ld:%d:%llu.\n", vha->host_no, id, lun);
1173 1175
1174 if (qla2x00_wait_for_hba_online(vha) != QLA_SUCCESS) { 1176 if (qla2x00_wait_for_hba_online(vha) != QLA_SUCCESS) {
1175 ql_log(ql_log_fatal, vha, 0x8013, 1177 ql_log(ql_log_fatal, vha, 0x8013,
@@ -1193,7 +1195,7 @@ qla2xxx_eh_bus_reset(struct scsi_cmnd *cmd)
1193 1195
1194eh_bus_reset_done: 1196eh_bus_reset_done:
1195 ql_log(ql_log_warn, vha, 0x802b, 1197 ql_log(ql_log_warn, vha, 0x802b,
1196 "BUS RESET %s nexus=%ld:%d:%d.\n", 1198 "BUS RESET %s nexus=%ld:%d:%llu.\n",
1197 (ret == FAILED) ? "FAILED" : "SUCCEEDED", vha->host_no, id, lun); 1199 (ret == FAILED) ? "FAILED" : "SUCCEEDED", vha->host_no, id, lun);
1198 1200
1199 return ret; 1201 return ret;
@@ -1220,14 +1222,15 @@ qla2xxx_eh_host_reset(struct scsi_cmnd *cmd)
1220 scsi_qla_host_t *vha = shost_priv(cmd->device->host); 1222 scsi_qla_host_t *vha = shost_priv(cmd->device->host);
1221 struct qla_hw_data *ha = vha->hw; 1223 struct qla_hw_data *ha = vha->hw;
1222 int ret = FAILED; 1224 int ret = FAILED;
1223 unsigned int id, lun; 1225 unsigned int id;
1226 uint64_t lun;
1224 scsi_qla_host_t *base_vha = pci_get_drvdata(ha->pdev); 1227 scsi_qla_host_t *base_vha = pci_get_drvdata(ha->pdev);
1225 1228
1226 id = cmd->device->id; 1229 id = cmd->device->id;
1227 lun = cmd->device->lun; 1230 lun = cmd->device->lun;
1228 1231
1229 ql_log(ql_log_info, vha, 0x8018, 1232 ql_log(ql_log_info, vha, 0x8018,
1230 "ADAPTER RESET ISSUED nexus=%ld:%d:%d.\n", vha->host_no, id, lun); 1233 "ADAPTER RESET ISSUED nexus=%ld:%d:%llu.\n", vha->host_no, id, lun);
1231 1234
1232 /* 1235 /*
1233 * No point in issuing another reset if one is active. Also do not 1236 * No point in issuing another reset if one is active. Also do not
@@ -1273,7 +1276,7 @@ qla2xxx_eh_host_reset(struct scsi_cmnd *cmd)
1273 1276
1274eh_host_reset_lock: 1277eh_host_reset_lock:
1275 ql_log(ql_log_info, vha, 0x8017, 1278 ql_log(ql_log_info, vha, 0x8017,
1276 "ADAPTER RESET %s nexus=%ld:%d:%d.\n", 1279 "ADAPTER RESET %s nexus=%ld:%d:%llu.\n",
1277 (ret == FAILED) ? "FAILED" : "SUCCEEDED", vha->host_no, id, lun); 1280 (ret == FAILED) ? "FAILED" : "SUCCEEDED", vha->host_no, id, lun);
1278 1281
1279 return ret; 1282 return ret;
@@ -1409,7 +1412,7 @@ static void qla2x00_handle_queue_full(struct scsi_device *sdev, int qdepth)
1409 return; 1412 return;
1410 1413
1411 ql_dbg(ql_dbg_io, fcport->vha, 0x3029, 1414 ql_dbg(ql_dbg_io, fcport->vha, 0x3029,
1412 "Queue depth adjusted-down to %d for nexus=%ld:%d:%d.\n", 1415 "Queue depth adjusted-down to %d for nexus=%ld:%d:%llu.\n",
1413 sdev->queue_depth, fcport->vha->host_no, sdev->id, sdev->lun); 1416 sdev->queue_depth, fcport->vha->host_no, sdev->id, sdev->lun);
1414} 1417}
1415 1418
@@ -1432,7 +1435,7 @@ static void qla2x00_adjust_sdev_qdepth_up(struct scsi_device *sdev, int qdepth)
1432 scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, qdepth); 1435 scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, qdepth);
1433 1436
1434 ql_dbg(ql_dbg_io, vha, 0x302a, 1437 ql_dbg(ql_dbg_io, vha, 0x302a,
1435 "Queue depth adjusted-up to %d for nexus=%ld:%d:%d.\n", 1438 "Queue depth adjusted-up to %d for nexus=%ld:%d:%llu.\n",
1436 sdev->queue_depth, fcport->vha->host_no, sdev->id, sdev->lun); 1439 sdev->queue_depth, fcport->vha->host_no, sdev->id, sdev->lun);
1437} 1440}
1438 1441