Lines Matching refs:ctrl_ctx

1472 	struct xhci_input_control_ctx *ctrl_ctx;  in xhci_check_ep0_maxpacket()  local
1504 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_check_ep0_maxpacket()
1505 if (!ctrl_ctx) { in xhci_check_ep0_maxpacket()
1519 ctrl_ctx->add_flags = cpu_to_le32(EP0_FLAG); in xhci_check_ep0_maxpacket()
1520 ctrl_ctx->drop_flags = 0; in xhci_check_ep0_maxpacket()
1525 ctrl_ctx->add_flags = cpu_to_le32(SLOT_FLAG); in xhci_check_ep0_maxpacket()
1816 struct xhci_input_control_ctx *ctrl_ctx; in xhci_drop_endpoint() local
1840 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_drop_endpoint()
1841 if (!ctrl_ctx) { in xhci_drop_endpoint()
1853 le32_to_cpu(ctrl_ctx->drop_flags) & in xhci_drop_endpoint()
1862 ctrl_ctx->drop_flags |= cpu_to_le32(drop_flag); in xhci_drop_endpoint()
1863 new_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags); in xhci_drop_endpoint()
1865 ctrl_ctx->add_flags &= cpu_to_le32(~drop_flag); in xhci_drop_endpoint()
1866 new_add_flags = le32_to_cpu(ctrl_ctx->add_flags); in xhci_drop_endpoint()
1900 struct xhci_input_control_ctx *ctrl_ctx; in xhci_add_endpoint() local
1930 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_add_endpoint()
1931 if (!ctrl_ctx) { in xhci_add_endpoint()
1942 !(le32_to_cpu(ctrl_ctx->drop_flags) & added_ctxs)) { in xhci_add_endpoint()
1952 if (le32_to_cpu(ctrl_ctx->add_flags) & added_ctxs) { in xhci_add_endpoint()
1969 ctrl_ctx->add_flags |= cpu_to_le32(added_ctxs); in xhci_add_endpoint()
1970 new_add_flags = le32_to_cpu(ctrl_ctx->add_flags); in xhci_add_endpoint()
1978 new_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags); in xhci_add_endpoint()
1997 struct xhci_input_control_ctx *ctrl_ctx; in xhci_zero_in_ctx() local
2002 ctrl_ctx = xhci_get_input_control_ctx(virt_dev->in_ctx); in xhci_zero_in_ctx()
2003 if (!ctrl_ctx) { in xhci_zero_in_ctx()
2014 ctrl_ctx->drop_flags = 0; in xhci_zero_in_ctx()
2015 ctrl_ctx->add_flags = 0; in xhci_zero_in_ctx()
2130 struct xhci_input_control_ctx *ctrl_ctx) in xhci_count_num_new_endpoints() argument
2139 valid_add_flags = le32_to_cpu(ctrl_ctx->add_flags) >> 2; in xhci_count_num_new_endpoints()
2140 valid_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags) >> 2; in xhci_count_num_new_endpoints()
2151 struct xhci_input_control_ctx *ctrl_ctx) in xhci_count_num_dropped_endpoints() argument
2156 valid_add_flags = le32_to_cpu(ctrl_ctx->add_flags) >> 2; in xhci_count_num_dropped_endpoints()
2157 valid_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags) >> 2; in xhci_count_num_dropped_endpoints()
2177 struct xhci_input_control_ctx *ctrl_ctx) in xhci_reserve_host_resources() argument
2181 added_eps = xhci_count_num_new_endpoints(xhci, ctrl_ctx); in xhci_reserve_host_resources()
2204 struct xhci_input_control_ctx *ctrl_ctx) in xhci_free_host_resources() argument
2208 num_failed_eps = xhci_count_num_new_endpoints(xhci, ctrl_ctx); in xhci_free_host_resources()
2223 struct xhci_input_control_ctx *ctrl_ctx) in xhci_finish_resource_reservation() argument
2227 num_dropped_eps = xhci_count_num_dropped_endpoints(xhci, ctrl_ctx); in xhci_finish_resource_reservation()
2714 struct xhci_input_control_ctx *ctrl_ctx; in xhci_reserve_bandwidth() local
2720 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_reserve_bandwidth()
2721 if (!ctrl_ctx) { in xhci_reserve_bandwidth()
2728 if (!EP_IS_ADDED(ctrl_ctx, i) && !EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2737 if (EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2746 xhci_update_bw_info(xhci, virt_dev->in_ctx, ctrl_ctx, virt_dev); in xhci_reserve_bandwidth()
2749 if (EP_IS_ADDED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2768 if (!EP_IS_ADDED(ctrl_ctx, i) && !EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2774 if (EP_IS_ADDED(ctrl_ctx, i)) { in xhci_reserve_bandwidth()
2786 if (EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2808 struct xhci_input_control_ctx *ctrl_ctx; in xhci_configure_endpoint() local
2824 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_configure_endpoint()
2825 if (!ctrl_ctx) { in xhci_configure_endpoint()
2833 xhci_reserve_host_resources(xhci, ctrl_ctx)) { in xhci_configure_endpoint()
2843 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
2851 trace_xhci_configure_endpoint_ctrl_ctx(ctrl_ctx); in xhci_configure_endpoint()
2864 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
2889 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
2891 xhci_finish_resource_reservation(xhci, ctrl_ctx); in xhci_configure_endpoint()
2927 struct xhci_input_control_ctx *ctrl_ctx; in xhci_check_bandwidth() local
2949 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_check_bandwidth()
2950 if (!ctrl_ctx) { in xhci_check_bandwidth()
2956 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_check_bandwidth()
2957 ctrl_ctx->add_flags &= cpu_to_le32(~EP0_FLAG); in xhci_check_bandwidth()
2958 ctrl_ctx->drop_flags &= cpu_to_le32(~(SLOT_FLAG | EP0_FLAG)); in xhci_check_bandwidth()
2961 if (ctrl_ctx->add_flags == cpu_to_le32(SLOT_FLAG) && in xhci_check_bandwidth()
2962 ctrl_ctx->drop_flags == 0) { in xhci_check_bandwidth()
2971 if ((virt_dev->eps[i-1].ring && !(ctrl_ctx->drop_flags & le32)) in xhci_check_bandwidth()
2972 || (ctrl_ctx->add_flags & le32) || i == 1) { in xhci_check_bandwidth()
2987 if ((le32_to_cpu(ctrl_ctx->drop_flags) & (1 << (i + 1))) && in xhci_check_bandwidth()
2988 !(le32_to_cpu(ctrl_ctx->add_flags) & (1 << (i + 1)))) { in xhci_check_bandwidth()
3048 struct xhci_input_control_ctx *ctrl_ctx, in xhci_setup_input_ctx_for_config_ep() argument
3051 ctrl_ctx->add_flags = cpu_to_le32(add_flags); in xhci_setup_input_ctx_for_config_ep()
3052 ctrl_ctx->drop_flags = cpu_to_le32(drop_flags); in xhci_setup_input_ctx_for_config_ep()
3054 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_setup_input_ctx_for_config_ep()
3119 struct xhci_input_control_ctx *ctrl_ctx; in xhci_endpoint_reset() local
3222 ctrl_ctx = xhci_get_input_control_ctx(cfg_cmd->in_ctx); in xhci_endpoint_reset()
3223 if (!ctrl_ctx) { in xhci_endpoint_reset()
3232 ctrl_ctx, ep_flag, ep_flag); in xhci_endpoint_reset()
3422 struct xhci_input_control_ctx *ctrl_ctx; in xhci_alloc_streams() local
3451 ctrl_ctx = xhci_get_input_control_ctx(config_cmd->in_ctx); in xhci_alloc_streams()
3452 if (!ctrl_ctx) { in xhci_alloc_streams()
3526 vdev->out_ctx, ctrl_ctx, in xhci_alloc_streams()
3589 struct xhci_input_control_ctx *ctrl_ctx; in xhci_free_streams() local
3612 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_free_streams()
3613 if (!ctrl_ctx) { in xhci_free_streams()
3634 vdev->out_ctx, ctrl_ctx, in xhci_free_streams()
4089 struct xhci_input_control_ctx *ctrl_ctx; in xhci_setup_device() local
4141 ctrl_ctx = xhci_get_input_control_ctx(virt_dev->in_ctx); in xhci_setup_device()
4142 if (!ctrl_ctx) { in xhci_setup_device()
4158 ctrl_ctx->add_flags = cpu_to_le32(SLOT_FLAG | EP0_FLAG); in xhci_setup_device()
4159 ctrl_ctx->drop_flags = 0; in xhci_setup_device()
4164 trace_xhci_address_ctrl_ctx(ctrl_ctx); in xhci_setup_device()
4250 ctrl_ctx->add_flags = 0; in xhci_setup_device()
4251 ctrl_ctx->drop_flags = 0; in xhci_setup_device()
4302 struct xhci_input_control_ctx *ctrl_ctx; in xhci_change_max_exit_latency() local
4328 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_change_max_exit_latency()
4329 if (!ctrl_ctx) { in xhci_change_max_exit_latency()
4340 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_change_max_exit_latency()
5041 struct xhci_input_control_ctx *ctrl_ctx; in xhci_update_hub_device() local
5061 ctrl_ctx = xhci_get_input_control_ctx(config_cmd->in_ctx); in xhci_update_hub_device()
5062 if (!ctrl_ctx) { in xhci_update_hub_device()
5079 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_update_hub_device()