aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/bnx2fc/bnx2fc_io.c4
-rw-r--r--drivers/scsi/libfc/fc_fcp.c5
2 files changed, 3 insertions, 6 deletions
diff --git a/drivers/scsi/bnx2fc/bnx2fc_io.c b/drivers/scsi/bnx2fc/bnx2fc_io.c
index 84a78af83f90..e897ce975bb8 100644
--- a/drivers/scsi/bnx2fc/bnx2fc_io.c
+++ b/drivers/scsi/bnx2fc/bnx2fc_io.c
@@ -1682,9 +1682,7 @@ void bnx2fc_build_fcp_cmnd(struct bnx2fc_cmd *io_req,
1682 1682
1683 memset(fcp_cmnd, 0, sizeof(struct fcp_cmnd)); 1683 memset(fcp_cmnd, 0, sizeof(struct fcp_cmnd));
1684 1684
1685 int_to_scsilun(sc_cmd->device->lun, 1685 int_to_scsilun(sc_cmd->device->lun, &fcp_cmnd->fc_lun);
1686 (struct scsi_lun *) fcp_cmnd->fc_lun);
1687
1688 1686
1689 fcp_cmnd->fc_dl = htonl(io_req->data_xfer_len); 1687 fcp_cmnd->fc_dl = htonl(io_req->data_xfer_len);
1690 memcpy(fcp_cmnd->fc_cdb, sc_cmd->cmnd, sc_cmd->cmd_len); 1688 memcpy(fcp_cmnd->fc_cdb, sc_cmd->cmnd, sc_cmd->cmd_len);
diff --git a/drivers/scsi/libfc/fc_fcp.c b/drivers/scsi/libfc/fc_fcp.c
index b577c907b318..f7357308655a 100644
--- a/drivers/scsi/libfc/fc_fcp.c
+++ b/drivers/scsi/libfc/fc_fcp.c
@@ -1074,8 +1074,7 @@ static int fc_fcp_pkt_send(struct fc_lport *lport, struct fc_fcp_pkt *fsp)
1074 fsp->cdb_cmd.fc_dl = htonl(fsp->data_len); 1074 fsp->cdb_cmd.fc_dl = htonl(fsp->data_len);
1075 fsp->cdb_cmd.fc_flags = fsp->req_flags & ~FCP_CFL_LEN_MASK; 1075 fsp->cdb_cmd.fc_flags = fsp->req_flags & ~FCP_CFL_LEN_MASK;
1076 1076
1077 int_to_scsilun(fsp->cmd->device->lun, 1077 int_to_scsilun(fsp->cmd->device->lun, &fsp->cdb_cmd.fc_lun);
1078 (struct scsi_lun *)fsp->cdb_cmd.fc_lun);
1079 memcpy(fsp->cdb_cmd.fc_cdb, fsp->cmd->cmnd, fsp->cmd->cmd_len); 1078 memcpy(fsp->cdb_cmd.fc_cdb, fsp->cmd->cmnd, fsp->cmd->cmd_len);
1080 1079
1081 spin_lock_irqsave(&si->scsi_queue_lock, flags); 1080 spin_lock_irqsave(&si->scsi_queue_lock, flags);
@@ -1257,7 +1256,7 @@ static int fc_lun_reset(struct fc_lport *lport, struct fc_fcp_pkt *fsp,
1257 1256
1258 fsp->cdb_cmd.fc_dl = htonl(fsp->data_len); 1257 fsp->cdb_cmd.fc_dl = htonl(fsp->data_len);
1259 fsp->cdb_cmd.fc_tm_flags = FCP_TMF_LUN_RESET; 1258 fsp->cdb_cmd.fc_tm_flags = FCP_TMF_LUN_RESET;
1260 int_to_scsilun(lun, (struct scsi_lun *)fsp->cdb_cmd.fc_lun); 1259 int_to_scsilun(lun, &fsp->cdb_cmd.fc_lun);
1261 1260
1262 fsp->wait_for_comp = 1; 1261 fsp->wait_for_comp = 1;
1263 init_completion(&fsp->tm_done); 1262 init_completion(&fsp->tm_done);