Lines Matching refs:sctx
1008 XHCIStreamContext *sctx; in xhci_find_stream() local
1018 sctx = epctx->pstreams + streamid; in xhci_find_stream()
1025 if (sctx->sct == -1) { in xhci_find_stream()
1026 xhci_dma_read_u32s(epctx->xhci, sctx->pctx, ctx, sizeof(ctx)); in xhci_find_stream()
1032 sctx->sct = sct; in xhci_find_stream()
1034 xhci_ring_init(epctx->xhci, &sctx->ring, base); in xhci_find_stream()
1036 return sctx; in xhci_find_stream()
1040 XHCIStreamContext *sctx, uint32_t state) in xhci_set_ep_state() argument
1052 if (sctx != NULL) { in xhci_set_ep_state()
1053 ring = &sctx->ring; in xhci_set_ep_state()
1054 xhci_dma_read_u32s(xhci, sctx->pctx, ctx2, sizeof(ctx2)); in xhci_set_ep_state()
1056 ctx2[0] |= sctx->ring.dequeue | sctx->ring.ccs; in xhci_set_ep_state()
1057 ctx2[1] = (sctx->ring.dequeue >> 16) >> 16; in xhci_set_ep_state()
1058 xhci_dma_write_u32s(xhci, sctx->pctx, ctx2, sizeof(ctx2)); in xhci_set_ep_state()
1396 XHCIStreamContext *sctx; in xhci_set_ep_dequeue() local
1425 sctx = xhci_find_stream(epctx, streamid, &err); in xhci_set_ep_dequeue()
1426 if (sctx == NULL) { in xhci_set_ep_dequeue()
1429 xhci_ring_init(xhci, &sctx->ring, dequeue & ~0xf); in xhci_set_ep_dequeue()
1430 sctx->ring.ccs = dequeue & 1; in xhci_set_ep_dequeue()
1432 sctx = NULL; in xhci_set_ep_dequeue()
1437 xhci_set_ep_state(xhci, epctx, sctx, EP_STOPPED); in xhci_set_ep_dequeue()
1574 XHCIStreamContext *sctx; in xhci_stall_ep() local
1582 sctx = xhci_find_stream(epctx, xfer->streamid, &err); in xhci_stall_ep()
1583 if (sctx == NULL) { in xhci_stall_ep()
1586 sctx->ring.dequeue = xfer->trbs[0].addr; in xhci_stall_ep()
1587 sctx->ring.ccs = xfer->trbs[0].ccs; in xhci_stall_ep()
1588 xhci_set_ep_state(xhci, epctx, sctx, EP_HALTED); in xhci_stall_ep()