Lines Matching defs:trb

101 				 struct cdns2_trb *trb)
103 u32 offset = (char *)trb - (char *)pep->ring.trbs;
171 * Increment a trb index.
229 struct cdns2_trb *trb)
231 if (trb == (pep->ring.trbs + (TRBS_PER_SEGMENT - 1)))
234 return ++trb;
282 struct cdns2_trb *trb)
294 pep->wa1_trb = trb;
368 struct cdns2_trb *trb = preq->trb;
373 trace_cdns2_queue_trb(pep, trb + i);
374 if (trb + i == link_trb) {
375 trb = pep->ring.trbs;
403 * One extra link trb for IN direction.
465 * Let's assume that driver prepares trb with trb->length 700 and burst size
505 struct cdns2_trb *trb;
587 trb = pep->ring.trbs + pep->ring.enqueue;
588 trb->buffer = cpu_to_le32(TRB_BUFFER(trb_dma));
589 trb->length = cpu_to_le32(length);
590 trb->control = cpu_to_le32(control);
621 struct cdns2_trb *trb;
640 trb = pep->ring.trbs + ring->enqueue;
652 trb->buffer = cpu_to_le32(pep->ring.dma +
654 trb->length = 0;
655 trb->control = cpu_to_le32(control);
673 trb->buffer = cpu_to_le32(trb_dma);
674 trb->length = cpu_to_le32(TRB_BURST(pep->trb_burst_size) |
676 trb->control = cpu_to_le32(control);
715 struct cdns2_trb *trb;
736 trb = &pep->ring.trbs[TRBS_PER_SEGMENT];
737 trb->length = 0;
738 trb->buffer = cpu_to_le32(TRB_BUFFER(buffer));
739 trb->control = cpu_to_le32((hw_ccs ? TRB_CYCLE : 0) | TRB_TYPE(TRB_NORMAL));
745 trb++;
746 trb->length = 0;
747 trb->buffer = cpu_to_le32(TRB_BUFFER(buffer));
748 trb->control = cpu_to_le32((hw_ccs ? TRB_CYCLE : 0) |
752 trb->control |= cpu_to_le32(TRB_TOGGLE);
785 preq->trb = ring->trbs + ring->enqueue;
803 preq->trb->control = preq->trb->control ^ cpu_to_le32(1);
844 * Check whether trb has been handled by DMA.
884 struct cdns2_trb *trb;
901 /* Current trb doesn't belong to this request. */
917 trb = &ring->trbs[ring->dequeue];
919 if ((le32_to_cpu(trb->control) & TRB_CYCLE) != ring->ccs)
954 struct cdns2_trb *trb;
957 trb = pep->ring.trbs + pep->ring.dequeue;
961 trace_cdns2_complete_trb(pep, trb);
963 trb = cdns2_next_trb(pep, trb);
977 struct cdns2_trb *trb;
981 trb = pep->ring.trbs + pep->ring.dequeue;
987 while (TRB_FIELD_TO_TYPE(le32_to_cpu(trb->control)) == TRB_LINK &&
988 le32_to_cpu(trb->length)) {
989 trace_cdns2_complete_trb(pep, trb);
991 trb = pep->ring.trbs + pep->ring.dequeue;
1006 trb = pep->ring.trbs + pep->ring.dequeue;
1007 trace_cdns2_complete_trb(pep, trb);
1012 * trb->length.
1017 TRB_LEN(le32_to_cpu(trb->length));
1784 link_trb = preq->trb;
1808 if (pep->wa1_trb == preq->trb)
1841 struct cdns2_trb *trb = NULL;
1847 trb = preq->trb;
1848 if (trb) {
1849 trb_tmp = *trb;
1850 trb->control = trb->control ^ cpu_to_le32(TRB_CYCLE);
1866 if (trb)
1867 *trb = trb_tmp;