Lines Matching refs:scsi_cmnd
88 lpfc_prot_group_type(struct lpfc_hba *phba, struct scsi_cmnd *sc);
91 lpfc_cmd_blksize(struct scsi_cmnd *sc) in lpfc_cmd_blksize()
99 lpfc_cmd_protect(struct scsi_cmnd *sc, int flag) in lpfc_cmd_protect()
105 lpfc_cmd_guard_csum(struct scsi_cmnd *sc) in lpfc_cmd_guard_csum()
149 struct scsi_cmnd *cmd = lpfc_cmd->pCmd; in lpfc_update_stats()
592 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf_s3()
631 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf_s4()
743 struct scsi_cmnd *cmnd) in lpfc_get_scsi_buf()
837 struct scsi_cmnd *scsi_cmnd = lpfc_cmd->pCmd; in lpfc_scsi_prep_dma_buf_s3() local
846 int nseg, datadir = scsi_cmnd->sc_data_direction; in lpfc_scsi_prep_dma_buf_s3()
855 if (scsi_sg_count(scsi_cmnd)) { in lpfc_scsi_prep_dma_buf_s3()
863 nseg = dma_map_sg(&phba->pcidev->dev, scsi_sglist(scsi_cmnd), in lpfc_scsi_prep_dma_buf_s3()
864 scsi_sg_count(scsi_cmnd), datadir); in lpfc_scsi_prep_dma_buf_s3()
877 scsi_dma_unmap(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s3()
890 scsi_for_each_sg(scsi_cmnd, sgel, nseg, num_bde) { in lpfc_scsi_prep_dma_buf_s3()
949 fcp_cmnd->fcpDl = cpu_to_be32(scsi_bufflen(scsi_cmnd)); in lpfc_scsi_prep_dma_buf_s3()
955 iocb_cmd->un.fcpi.fcpi_parm = scsi_bufflen(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s3()
984 lpfc_bg_err_inject(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_err_inject()
1391 lpfc_sc_to_bg_opcodes(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_sc_to_bg_opcodes()
1471 lpfc_bg_err_opcodes(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_err_opcodes()
1563 lpfc_bg_setup_bpl(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_setup_bpl()
1703 lpfc_bg_setup_bpl_prot(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_setup_bpl_prot()
1948 lpfc_bg_setup_sgl(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_setup_sgl()
2128 lpfc_bg_setup_sgl_prot(struct lpfc_hba *phba, struct scsi_cmnd *sc, in lpfc_bg_setup_sgl_prot()
2440 lpfc_prot_group_type(struct lpfc_hba *phba, struct scsi_cmnd *sc) in lpfc_prot_group_type()
2480 struct scsi_cmnd *sc = lpfc_cmd->pCmd; in lpfc_bg_scsi_adjust_dl()
2523 struct scsi_cmnd *scsi_cmnd = lpfc_cmd->pCmd; in lpfc_bg_scsi_prep_dma_buf_s3() local
2528 int datasegcnt, protsegcnt, datadir = scsi_cmnd->sc_data_direction; in lpfc_bg_scsi_prep_dma_buf_s3()
2539 if (scsi_sg_count(scsi_cmnd)) { in lpfc_bg_scsi_prep_dma_buf_s3()
2547 scsi_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s3()
2548 scsi_sg_count(scsi_cmnd), datadir); in lpfc_bg_scsi_prep_dma_buf_s3()
2561 prot_group_type = lpfc_prot_group_type(phba, scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s3()
2572 num_bde = lpfc_bg_setup_bpl(phba, scsi_cmnd, bpl, in lpfc_bg_scsi_prep_dma_buf_s3()
2588 scsi_prot_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s3()
2589 scsi_prot_sg_count(scsi_cmnd), datadir); in lpfc_bg_scsi_prep_dma_buf_s3()
2591 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s3()
2607 num_bde = lpfc_bg_setup_bpl_prot(phba, scsi_cmnd, bpl, in lpfc_bg_scsi_prep_dma_buf_s3()
2619 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s3()
2660 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s3()
2662 dma_unmap_sg(&phba->pcidev->dev, scsi_prot_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s3()
2663 scsi_prot_sg_count(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s3()
2664 scsi_cmnd->sc_data_direction); in lpfc_bg_scsi_prep_dma_buf_s3()
2717 struct scsi_cmnd *cmd = lpfc_cmd->pCmd; in lpfc_calc_bg_err()
2901 struct scsi_cmnd *cmd = lpfc_cmd->pCmd; in lpfc_parse_bg_err()
3048 struct scsi_cmnd *scsi_cmnd = lpfc_cmd->pCmd; in lpfc_scsi_prep_dma_buf_s4() local
3069 if (scsi_sg_count(scsi_cmnd)) { in lpfc_scsi_prep_dma_buf_s4()
3077 nseg = scsi_dma_map(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s4()
3098 scsi_dma_unmap(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s4()
3113 sgel = scsi_sglist(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s4()
3137 scsi_dma_unmap(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s4()
3223 fcp_cmnd->fcpDl = cpu_to_be32(scsi_bufflen(scsi_cmnd)); in lpfc_scsi_prep_dma_buf_s4()
3229 iocb_cmd->un.fcpi.fcpi_parm = scsi_bufflen(scsi_cmnd); in lpfc_scsi_prep_dma_buf_s4()
3236 scsi_cmnd->device->hostdata)->oas_enabled) { in lpfc_scsi_prep_dma_buf_s4()
3239 scsi_cmnd->device->hostdata)->priority; in lpfc_scsi_prep_dma_buf_s4()
3262 struct scsi_cmnd *scsi_cmnd = lpfc_cmd->pCmd; in lpfc_bg_scsi_prep_dma_buf_s4() local
3267 int datasegcnt, protsegcnt, datadir = scsi_cmnd->sc_data_direction; in lpfc_bg_scsi_prep_dma_buf_s4()
3277 if (scsi_sg_count(scsi_cmnd)) { in lpfc_bg_scsi_prep_dma_buf_s4()
3285 scsi_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s4()
3286 scsi_sg_count(scsi_cmnd), datadir); in lpfc_bg_scsi_prep_dma_buf_s4()
3307 prot_group_type = lpfc_prot_group_type(phba, scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s4()
3319 num_sge = lpfc_bg_setup_sgl(phba, scsi_cmnd, sgl, in lpfc_bg_scsi_prep_dma_buf_s4()
3336 scsi_prot_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s4()
3337 scsi_prot_sg_count(scsi_cmnd), datadir); in lpfc_bg_scsi_prep_dma_buf_s4()
3339 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s4()
3355 num_sge = lpfc_bg_setup_sgl_prot(phba, scsi_cmnd, sgl, in lpfc_bg_scsi_prep_dma_buf_s4()
3369 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s4()
3379 switch (scsi_get_prot_op(scsi_cmnd)) { in lpfc_bg_scsi_prep_dma_buf_s4()
3416 scsi_cmnd->device->hostdata)->oas_enabled) in lpfc_bg_scsi_prep_dma_buf_s4()
3422 scsi_dma_unmap(scsi_cmnd); in lpfc_bg_scsi_prep_dma_buf_s4()
3424 dma_unmap_sg(&phba->pcidev->dev, scsi_prot_sglist(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s4()
3425 scsi_prot_sg_count(scsi_cmnd), in lpfc_bg_scsi_prep_dma_buf_s4()
3426 scsi_cmnd->sc_data_direction); in lpfc_bg_scsi_prep_dma_buf_s4()
3490 struct scsi_cmnd *cmnd = lpfc_cmd->pCmd; in lpfc_send_scsi_error_event()
3612 struct scsi_cmnd *cmnd = lpfc_cmd->pCmd; in lpfc_handle_fcp_err()
3805 struct scsi_cmnd *cmd; in lpfc_scsi_cmd_iocb_cmpl()
4087 struct scsi_cmnd *scsi_cmnd = lpfc_cmd->pCmd; in lpfc_scsi_prep_cmnd() local
4092 int datadir = scsi_cmnd->sc_data_direction; in lpfc_scsi_prep_cmnd()
4109 memcpy(ptr, scsi_cmnd->cmnd, scsi_cmnd->cmd_len); in lpfc_scsi_prep_cmnd()
4110 if (scsi_cmnd->cmd_len < LPFC_FCP_CDB_LEN) { in lpfc_scsi_prep_cmnd()
4111 ptr += scsi_cmnd->cmd_len; in lpfc_scsi_prep_cmnd()
4112 memset(ptr, 0, (LPFC_FCP_CDB_LEN - scsi_cmnd->cmd_len)); in lpfc_scsi_prep_cmnd()
4129 if (scsi_sg_count(scsi_cmnd)) { in lpfc_scsi_prep_cmnd()
4135 fcpdl = scsi_bufflen(scsi_cmnd); in lpfc_scsi_prep_cmnd()
4502 lpfc_queuecommand(struct Scsi_Host *shost, struct scsi_cmnd *cmnd) in lpfc_queuecommand()
4726 lpfc_abort_handler(struct scsi_cmnd *cmnd) in lpfc_abort_handler()
5032 lpfc_send_taskmgmt(struct lpfc_vport *vport, struct scsi_cmnd *cmnd, in lpfc_send_taskmgmt()
5131 lpfc_chk_tgt_mapped(struct lpfc_vport *vport, struct scsi_cmnd *cmnd) in lpfc_chk_tgt_mapped()
5224 lpfc_device_reset_handler(struct scsi_cmnd *cmnd) in lpfc_device_reset_handler()
5295 lpfc_target_reset_handler(struct scsi_cmnd *cmnd) in lpfc_target_reset_handler()
5373 lpfc_bus_reset_handler(struct scsi_cmnd *cmnd) in lpfc_bus_reset_handler()
5465 lpfc_host_reset_handler(struct scsi_cmnd *cmnd) in lpfc_host_reset_handler()
5997 lpfc_no_command(struct Scsi_Host *shost, struct scsi_cmnd *cmnd) in lpfc_no_command()
6003 lpfc_no_handler(struct scsi_cmnd *cmnd) in lpfc_no_handler()