Lines Matching defs:sc_cmd

1064 	struct scsi_cmnd *sc_cmd;
1070 sc_cmd = fsp->cmd;
1071 if (id != -1 && scmd_id(sc_cmd) != id)
1074 if (lun != -1 && sc_cmd->device->lun != lun)
1853 * @sc_cmd: The scsi_cmnd to be executed
1857 int fc_queuecommand(struct Scsi_Host *shost, struct scsi_cmnd *sc_cmd)
1860 struct fc_rport *rport = starget_to_rport(scsi_target(sc_cmd->device));
1867 sc_cmd->result = rval;
1868 scsi_done(sc_cmd);
1877 sc_cmd->result = DID_IMM_RETRY << 16;
1878 scsi_done(sc_cmd);
1903 fsp->cmd = sc_cmd; /* save the cmd */
1909 fsp->data_len = scsi_bufflen(sc_cmd);
1915 if (sc_cmd->sc_data_direction == DMA_FROM_DEVICE) {
1919 } else if (sc_cmd->sc_data_direction == DMA_TO_DEVICE) {
1954 struct scsi_cmnd *sc_cmd;
1978 sc_cmd = fsp->cmd;
1979 libfc_priv(sc_cmd)->status = fsp->cdb_status;
1986 sc_cmd->result = DID_OK << 16;
1988 libfc_priv(sc_cmd)->resid_len = fsp->scsi_resid;
1994 sc_cmd->result = (DID_OK << 16) | fsp->cdb_status;
2000 sc_cmd->result = DID_ERROR << 16;
2009 sc_cmd->result = DID_OK << 16;
2013 sc_cmd->result = DID_ERROR << 16;
2021 libfc_priv(sc_cmd)->resid_len = fsp->scsi_resid;
2022 sc_cmd->result = (DID_ERROR << 16) | fsp->cdb_status;
2031 sc_cmd->result = (DID_ERROR << 16) | fsp->cdb_status;
2034 if (host_byte(sc_cmd->result) == DID_TIME_OUT)
2040 set_host_byte(sc_cmd, DID_ERROR);
2042 sc_cmd->result |= fsp->io_status;
2047 sc_cmd->result = (DID_RESET << 16);
2052 sc_cmd->result = (DID_SOFT_ERROR << 16);
2057 sc_cmd->result = (DID_NO_CONNECT << 16);
2062 sc_cmd->result = (DID_PARITY << 16);
2067 sc_cmd->result = (DID_BUS_BUSY << 16) | fsp->io_status;
2072 sc_cmd->result = (DID_ERROR << 16);
2077 sc_cmd->result = (DID_TRANSPORT_DISRUPTED << 16);
2081 libfc_priv(sc_cmd)->fsp = NULL;
2083 scsi_done(sc_cmd);
2091 * @sc_cmd: The SCSI command to abort
2096 int fc_eh_abort(struct scsi_cmnd *sc_cmd)
2105 rval = fc_block_scsi_eh(sc_cmd);
2109 lport = shost_priv(sc_cmd->device->host);
2117 fsp = libfc_priv(sc_cmd)->fsp;
2123 /* grab a ref so the fsp and sc_cmd cannot be released from under us */
2144 * @sc_cmd: The SCSI command which identifies the device whose
2149 int fc_eh_device_reset(struct scsi_cmnd *sc_cmd)
2153 struct fc_rport *rport = starget_to_rport(scsi_target(sc_cmd->device));
2157 rval = fc_block_scsi_eh(sc_cmd);
2161 lport = shost_priv(sc_cmd->device->host);
2184 rc = fc_lun_reset(lport, fsp, scmd_id(sc_cmd), sc_cmd->device->lun);
2195 * @sc_cmd: The SCSI command that identifies the SCSI host to be reset
2197 int fc_eh_host_reset(struct scsi_cmnd *sc_cmd)
2199 struct Scsi_Host *shost = sc_cmd->device->host;