Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 161104
b: refs/heads/master
c: cf53b06
h: refs/heads/master
v: v3
  • Loading branch information
Andrew Vasquez authored and James Bottomley committed Sep 5, 2009
1 parent 1fa86e1 commit d9cf556
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: dc162b63bfc4201ca5c13df3fc8836c56979eb07
refs/heads/master: cf53b069f52ae3f83dec1acd339e3c3a2e979478
3 changes: 3 additions & 0 deletions trunk/drivers/scsi/qla2xxx/qla_def.h
Original file line number Diff line number Diff line change
Expand Up @@ -189,13 +189,16 @@ struct req_que;
*/
typedef struct srb {
struct fc_port *fcport;
uint32_t handle;

struct scsi_cmnd *cmd; /* Linux SCSI command pkt */

uint16_t flags;

uint32_t request_sense_length;
uint8_t *request_sense_ptr;

void *ctx;
} srb_t;

/*
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/scsi/qla2xxx/qla_iocb.c
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,7 @@ qla2x00_start_scsi(srb_t *sp)
/* Build command packet */
req->current_outstanding_cmd = handle;
req->outstanding_cmds[handle] = sp;
sp->handle = handle;
sp->cmd->host_scribble = (unsigned char *)(unsigned long)handle;
req->cnt -= req_cnt;

Expand Down Expand Up @@ -778,6 +779,7 @@ qla24xx_start_scsi(srb_t *sp)
/* Build command packet. */
req->current_outstanding_cmd = handle;
req->outstanding_cmds[handle] = sp;
sp->handle = handle;
sp->cmd->host_scribble = (unsigned char *)(unsigned long)handle;
req->cnt -= req_cnt;

Expand Down
11 changes: 9 additions & 2 deletions trunk/drivers/scsi/qla2xxx/qla_os.c
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,7 @@ qla2x00_get_new_sp(scsi_qla_host_t *vha, fc_port_t *fcport,
sp->flags = 0;
CMD_SP(cmd) = (void *)sp;
cmd->scsi_done = done;
sp->ctx = NULL;

return sp;
}
Expand Down Expand Up @@ -709,6 +710,8 @@ qla2x00_abort_fcport_cmds(fc_port_t *fcport)
continue;
if (sp->fcport != fcport)
continue;
if (sp->ctx)
continue;

spin_unlock_irqrestore(&ha->hardware_lock, flags);
if (ha->isp_ops->abort_command(sp)) {
Expand Down Expand Up @@ -794,7 +797,8 @@ qla2xxx_eh_abort(struct scsi_cmnd *cmd)

if (sp == NULL)
continue;

if (sp->ctx)
continue;
if (sp->cmd != cmd)
continue;

Expand Down Expand Up @@ -859,7 +863,8 @@ qla2x00_eh_wait_for_pending_commands(scsi_qla_host_t *vha, unsigned int t,
sp = req->outstanding_cmds[cnt];
if (!sp)
continue;

if (sp->ctx)
continue;
if (vha->vp_idx != sp->fcport->vha->vp_idx)
continue;
match = 0;
Expand Down Expand Up @@ -2986,6 +2991,8 @@ qla2x00_timer(scsi_qla_host_t *vha)
sp = req->outstanding_cmds[index];
if (!sp)
continue;
if (sp->ctx)
continue;
sfcp = sp->fcport;
if (!(sfcp->flags & FCF_TAPE_PRESENT))
continue;
Expand Down

0 comments on commit d9cf556

Please sign in to comment.