• Home
  • Raw
  • Download

Lines Matching refs:qc

431 static unsigned int sata_fsl_fill_sg(struct ata_queued_cmd *qc, void *cmd_desc,  in sata_fsl_fill_sg()  argument
455 for_each_sg(qc->sg, sg, qc->n_elem, si) { in sata_fsl_fill_sg()
464 ata_port_err(qc->ap, "s/g addr unaligned : 0x%llx\n", in sata_fsl_fill_sg()
467 ata_port_err(qc->ap, "s/g len unaligned : 0x%x\n", in sata_fsl_fill_sg()
505 static enum ata_completion_errors sata_fsl_qc_prep(struct ata_queued_cmd *qc) in sata_fsl_qc_prep() argument
507 struct ata_port *ap = qc->ap; in sata_fsl_qc_prep()
511 unsigned int tag = sata_fsl_tag(qc->hw_tag, hcr_base); in sata_fsl_qc_prep()
521 ata_tf_to_fis(&qc->tf, qc->dev->link->pmp, 1, (u8 *) &cd->cfis); in sata_fsl_qc_prep()
526 if (qc->tf.protocol == ATA_PROT_NCQ) { in sata_fsl_qc_prep()
532 if (ata_is_atapi(qc->tf.protocol)) { in sata_fsl_qc_prep()
535 memcpy((void *)&cd->acmd, qc->cdb, qc->dev->cdb_len); in sata_fsl_qc_prep()
538 if (qc->flags & ATA_QCFLAG_DMAMAP) in sata_fsl_qc_prep()
539 num_prde = sata_fsl_fill_sg(qc, (void *)cd, in sata_fsl_qc_prep()
543 if (qc->tf.protocol == ATA_PROT_NCQ) in sata_fsl_qc_prep()
555 static unsigned int sata_fsl_qc_issue(struct ata_queued_cmd *qc) in sata_fsl_qc_issue() argument
557 struct ata_port *ap = qc->ap; in sata_fsl_qc_issue()
560 unsigned int tag = sata_fsl_tag(qc->hw_tag, hcr_base); in sata_fsl_qc_issue()
567 iowrite32(qc->dev->link->pmp, CQPMP + hcr_base); in sata_fsl_qc_issue()
584 static bool sata_fsl_qc_fill_rtf(struct ata_queued_cmd *qc) in sata_fsl_qc_fill_rtf() argument
586 struct sata_fsl_port_priv *pp = qc->ap->private_data; in sata_fsl_qc_fill_rtf()
587 struct sata_fsl_host_priv *host_priv = qc->ap->host->private_data; in sata_fsl_qc_fill_rtf()
589 unsigned int tag = sata_fsl_tag(qc->hw_tag, hcr_base); in sata_fsl_qc_fill_rtf()
594 ata_tf_from_fis(cd->sfis, &qc->result_tf); in sata_fsl_qc_fill_rtf()
1067 static void sata_fsl_post_internal_cmd(struct ata_queued_cmd *qc) in sata_fsl_post_internal_cmd() argument
1069 if (qc->flags & ATA_QCFLAG_FAILED) in sata_fsl_post_internal_cmd()
1070 qc->err_mask |= AC_ERR_OTHER; in sata_fsl_post_internal_cmd()
1072 if (qc->err_mask) { in sata_fsl_post_internal_cmd()
1086 struct ata_queued_cmd *qc = NULL; in sata_fsl_error_intr() local
1158 qc = ata_qc_from_tag(ap, link->active_tag); in sata_fsl_error_intr()
1176 qc = ata_qc_from_tag(ap, link->active_tag); in sata_fsl_error_intr()
1186 if (qc) in sata_fsl_error_intr()
1187 qc->err_mask |= err_mask; in sata_fsl_error_intr()
1197 if (qc) in sata_fsl_error_intr()
1198 ata_link_abort(qc->dev->link); in sata_fsl_error_intr()
1209 struct ata_queued_cmd *qc; in sata_fsl_host_intr() local
1223 ata_qc_for_each_with_internal(ap, qc, tag) { in sata_fsl_host_intr()
1224 if (qc && ata_is_atapi(qc->tf.protocol)) { in sata_fsl_host_intr()
1288 qc = ata_qc_from_tag(ap, ATA_TAG_INTERNAL); in sata_fsl_host_intr()
1293 if (qc) { in sata_fsl_host_intr()
1294 ata_qc_complete(qc); in sata_fsl_host_intr()