Lines Matching defs:slot_id
481 unsigned int slot_id,
485 __le32 __iomem *db_addr = &xhci->dba->doorbell[slot_id];
486 struct xhci_virt_ep *ep = &xhci->devs[slot_id]->eps[ep_index];
499 trace_xhci_ring_ep_doorbell(slot_id, DB_VALUE(ep_index, stream_id));
508 unsigned int slot_id,
514 ep = &xhci->devs[slot_id]->eps[ep_index];
519 xhci_ring_ep_doorbell(xhci, slot_id, ep_index, 0);
527 xhci_ring_ep_doorbell(xhci, slot_id, ep_index,
533 unsigned int slot_id,
536 ring_doorbell_for_active_rings(xhci, slot_id, ep_index);
540 unsigned int slot_id,
543 if (slot_id == 0 || slot_id >= MAX_HC_SLOTS) {
544 xhci_warn(xhci, "Invalid slot_id %u\n", slot_id);
551 if (!xhci->devs[slot_id]) {
552 xhci_warn(xhci, "No xhci virt device for slot_id %u\n", slot_id);
556 return &xhci->devs[slot_id]->eps[ep_index];
571 xhci_warn(xhci, "Invalid stream_id %u request for slot_id %u ep_index %u\n",
572 stream_id, ep->vdev->slot_id, ep->ep_index);
579 /* Get the right ring for the given slot_id, ep_index and stream_id.
584 unsigned int slot_id, unsigned int ep_index,
589 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
621 unsigned int slot_id, unsigned int ep_index,
624 struct xhci_virt_device *dev = xhci->devs[slot_id];
638 ep_ring = xhci_triad_to_transfer_ring(xhci, slot_id,
728 STREAM_ID_FOR_TRB(stream_id), SLOT_ID_FOR_TRB(slot_id) |
905 static int xhci_reset_halted_ep(struct xhci_hcd *xhci, unsigned int slot_id,
919 ep_index, slot_id);
921 ret = xhci_queue_reset_ep(xhci, command, slot_id, ep_index, reset_type);
925 slot_id, ep_index, ret);
934 unsigned int slot_id = ep->vdev->slot_id;
959 err = xhci_reset_halted_ep(xhci, slot_id, ep->ep_index, reset_type);
987 unsigned int slot_id = ep->vdev->slot_id;
1043 err = xhci_move_dequeue_past_td(xhci, slot_id, ep->ep_index,
1090 static void xhci_handle_cmd_stop_ep(struct xhci_hcd *xhci, int slot_id,
1102 if (!xhci->devs[slot_id])
1104 slot_id);
1109 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
1158 xhci_queue_stop_endpoint(xhci, command, slot_id, ep_index, 0);
1173 ring_doorbell_for_active_rings(xhci, slot_id, ep_index);
1196 int slot_id, int ep_index)
1203 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
1219 slot_id, ep_index, stream_id);
1228 slot_id, ep_index);
1320 static void xhci_handle_cmd_set_deq(struct xhci_hcd *xhci, int slot_id,
1333 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
1369 slot_id);
1426 ring_doorbell_for_active_rings(xhci, slot_id, ep_index);
1429 static void xhci_handle_cmd_reset_ep(struct xhci_hcd *xhci, int slot_id,
1437 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
1460 ring_doorbell_for_active_rings(xhci, slot_id, ep_index);
1463 static void xhci_handle_cmd_enable_slot(struct xhci_hcd *xhci, int slot_id,
1467 command->slot_id = slot_id;
1469 command->slot_id = 0;
1472 static void xhci_handle_cmd_disable_slot(struct xhci_hcd *xhci, int slot_id)
1477 virt_dev = xhci->devs[slot_id];
1489 static void xhci_handle_cmd_config_ep(struct xhci_hcd *xhci, int slot_id,
1503 virt_dev = xhci->devs[slot_id];
1523 static void xhci_handle_cmd_addr_dev(struct xhci_hcd *xhci, int slot_id)
1528 vdev = xhci->devs[slot_id];
1535 static void xhci_handle_cmd_reset_dev(struct xhci_hcd *xhci, int slot_id)
1540 vdev = xhci->devs[slot_id];
1543 slot_id);
1666 unsigned int slot_id = TRB_TO_SLOT_ID(le32_to_cpu(event->flags));
1674 if (slot_id >= MAX_HC_SLOTS) {
1675 xhci_warn(xhci, "Invalid slot_id %u\n", slot_id);
1732 xhci_handle_cmd_enable_slot(xhci, slot_id, cmd, cmd_comp_code);
1735 xhci_handle_cmd_disable_slot(xhci, slot_id);
1739 xhci_handle_cmd_config_ep(xhci, slot_id, cmd_comp_code);
1744 xhci_handle_cmd_addr_dev(xhci, slot_id);
1747 WARN_ON(slot_id != TRB_TO_SLOT_ID(
1750 xhci_handle_cmd_stop_ep(xhci, slot_id, cmd_trb,
1754 WARN_ON(slot_id != TRB_TO_SLOT_ID(
1756 xhci_handle_cmd_set_deq(xhci, slot_id, cmd_trb, cmd_comp_code);
1764 WARN_ON(slot_id != TRB_TO_SLOT_ID(
1766 xhci_handle_cmd_reset_ep(xhci, slot_id, cmd_trb, cmd_comp_code);
1772 slot_id = TRB_TO_SLOT_ID(
1774 xhci_handle_cmd_reset_dev(xhci, slot_id);
1811 u32 slot_id;
1814 slot_id = TRB_TO_SLOT_ID(le32_to_cpu(event->generic.field[3]));
1815 if (!xhci->devs[slot_id]) {
1817 "unused slot %u\n", slot_id);
1822 slot_id);
1823 udev = xhci->devs[slot_id]->udev;
1865 int slot_id;
1918 slot_id = xhci_find_slot_id_by_port(hcd, xhci, hcd_portnum + 1);
1919 if (slot_id && xhci->devs[slot_id])
1920 xhci->devs[slot_id]->flags |= VDEV_PORT_ERROR;
1978 slot_id = xhci_find_slot_id_by_port(hcd, xhci, hcd_portnum + 1);
1979 if (slot_id && xhci->devs[slot_id])
1980 xhci_ring_device(xhci, slot_id);
2566 unsigned int slot_id;
2578 slot_id = TRB_TO_SLOT_ID(le32_to_cpu(event->flags));
2583 ep = xhci_get_virt_ep(xhci, slot_id, ep_index);
2595 slot_id, ep_index);
2621 slot_id, ep_index);
2644 slot_id, ep_index);
2651 slot_id, ep_index);
2656 slot_id, ep_index);
2661 slot_id, ep_index);
2665 xhci_dbg(xhci, "Stalled endpoint for slot %u ep %u\n", slot_id,
2671 slot_id, ep_index);
2676 slot_id, ep_index);
2681 slot_id, ep_index);
2688 slot_id, ep_index);
2695 slot_id, ep_index);
2701 slot_id, ep_index);
2706 slot_id, ep_index);
2739 slot_id, ep_index);
2745 slot_id, ep_index);
2752 slot_id, ep_index);
2762 trb_comp_code, slot_id, ep_index);
2789 slot_id, ep_index);
2804 slot_id, ep_index);
2896 slot_id, ep_index);
3319 ep_ring = xhci_triad_to_transfer_ring(xhci, xdev->slot_id, ep_index,
3411 static void giveback_first_trb(struct xhci_hcd *xhci, int slot_id,
3424 xhci_ring_ep_doorbell(xhci, slot_id, ep_index, stream_id);
3464 struct urb *urb, int slot_id, unsigned int ep_index)
3468 ep_ctx = xhci_get_ep_ctx(xhci, xhci->devs[slot_id]->out_ctx, ep_index);
3471 return xhci_queue_bulk_tx(xhci, mem_flags, urb, slot_id, ep_index);
3592 struct urb *urb, int slot_id, unsigned int ep_index)
3626 ret = prepare_transfer(xhci, xhci->devs[slot_id],
3735 ret = prepare_transfer(xhci, xhci->devs[slot_id],
3746 giveback_first_trb(xhci, slot_id, ep_index, urb->stream_id,
3753 struct urb *urb, int slot_id, unsigned int ep_index)
3785 ret = prepare_transfer(xhci, xhci->devs[slot_id],
3881 giveback_first_trb(xhci, slot_id, ep_index, 0,
4050 struct urb *urb, int slot_id, unsigned int ep_index)
4067 xep = &xhci->devs[slot_id]->eps[ep_index];
4068 ep_ring = xhci->devs[slot_id]->eps[ep_index].ring;
4103 ret = prepare_transfer(xhci, xhci->devs[slot_id], ep_index,
4208 giveback_first_trb(xhci, slot_id, ep_index, urb->stream_id,
4242 struct urb *urb, int slot_id, unsigned int ep_index)
4253 xdev = xhci->devs[slot_id];
4254 xep = &xhci->devs[slot_id]->eps[ep_index];
4312 return xhci_queue_isoc_tx(xhci, mem_flags, urb, slot_id, ep_index);
4368 u32 trb_type, u32 slot_id)
4371 TRB_TYPE(trb_type) | SLOT_ID_FOR_TRB(slot_id), false);
4376 dma_addr_t in_ctx_ptr, u32 slot_id, enum xhci_setup_dev setup)
4380 TRB_TYPE(TRB_ADDR_DEV) | SLOT_ID_FOR_TRB(slot_id)
4392 u32 slot_id)
4395 TRB_TYPE(TRB_RESET_DEV) | SLOT_ID_FOR_TRB(slot_id),
4402 u32 slot_id, bool command_must_succeed)
4406 TRB_TYPE(TRB_CONFIG_EP) | SLOT_ID_FOR_TRB(slot_id),
4412 dma_addr_t in_ctx_ptr, u32 slot_id, bool command_must_succeed)
4416 TRB_TYPE(TRB_EVAL_CONTEXT) | SLOT_ID_FOR_TRB(slot_id),
4425 int slot_id, unsigned int ep_index, int suspend)
4427 u32 trb_slot_id = SLOT_ID_FOR_TRB(slot_id);
4437 int slot_id, unsigned int ep_index,
4440 u32 trb_slot_id = SLOT_ID_FOR_TRB(slot_id);