Lines Matching refs:ctrl_ctx
1551 struct xhci_input_control_ctx *ctrl_ctx; in xhci_check_ep0_maxpacket() local
1583 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_check_ep0_maxpacket()
1584 if (!ctrl_ctx) { in xhci_check_ep0_maxpacket()
1598 ctrl_ctx->add_flags = cpu_to_le32(EP0_FLAG); in xhci_check_ep0_maxpacket()
1599 ctrl_ctx->drop_flags = 0; in xhci_check_ep0_maxpacket()
1604 ctrl_ctx->add_flags = cpu_to_le32(SLOT_FLAG); in xhci_check_ep0_maxpacket()
1907 struct xhci_input_control_ctx *ctrl_ctx; in xhci_drop_endpoint() local
1931 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_drop_endpoint()
1932 if (!ctrl_ctx) { in xhci_drop_endpoint()
1944 le32_to_cpu(ctrl_ctx->drop_flags) & in xhci_drop_endpoint()
1953 ctrl_ctx->drop_flags |= cpu_to_le32(drop_flag); in xhci_drop_endpoint()
1954 new_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags); in xhci_drop_endpoint()
1956 ctrl_ctx->add_flags &= cpu_to_le32(~drop_flag); in xhci_drop_endpoint()
1957 new_add_flags = le32_to_cpu(ctrl_ctx->add_flags); in xhci_drop_endpoint()
1991 struct xhci_input_control_ctx *ctrl_ctx; in xhci_add_endpoint() local
2021 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_add_endpoint()
2022 if (!ctrl_ctx) { in xhci_add_endpoint()
2033 !(le32_to_cpu(ctrl_ctx->drop_flags) & added_ctxs)) { in xhci_add_endpoint()
2043 if (le32_to_cpu(ctrl_ctx->add_flags) & added_ctxs) { in xhci_add_endpoint()
2060 ctrl_ctx->add_flags |= cpu_to_le32(added_ctxs); in xhci_add_endpoint()
2061 new_add_flags = le32_to_cpu(ctrl_ctx->add_flags); in xhci_add_endpoint()
2069 new_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags); in xhci_add_endpoint()
2088 struct xhci_input_control_ctx *ctrl_ctx; in xhci_zero_in_ctx() local
2093 ctrl_ctx = xhci_get_input_control_ctx(virt_dev->in_ctx); in xhci_zero_in_ctx()
2094 if (!ctrl_ctx) { in xhci_zero_in_ctx()
2105 ctrl_ctx->drop_flags = 0; in xhci_zero_in_ctx()
2106 ctrl_ctx->add_flags = 0; in xhci_zero_in_ctx()
2221 struct xhci_input_control_ctx *ctrl_ctx) in xhci_count_num_new_endpoints() argument
2230 valid_add_flags = le32_to_cpu(ctrl_ctx->add_flags) >> 2; in xhci_count_num_new_endpoints()
2231 valid_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags) >> 2; in xhci_count_num_new_endpoints()
2242 struct xhci_input_control_ctx *ctrl_ctx) in xhci_count_num_dropped_endpoints() argument
2247 valid_add_flags = le32_to_cpu(ctrl_ctx->add_flags) >> 2; in xhci_count_num_dropped_endpoints()
2248 valid_drop_flags = le32_to_cpu(ctrl_ctx->drop_flags) >> 2; in xhci_count_num_dropped_endpoints()
2268 struct xhci_input_control_ctx *ctrl_ctx) in xhci_reserve_host_resources() argument
2272 added_eps = xhci_count_num_new_endpoints(xhci, ctrl_ctx); in xhci_reserve_host_resources()
2295 struct xhci_input_control_ctx *ctrl_ctx) in xhci_free_host_resources() argument
2299 num_failed_eps = xhci_count_num_new_endpoints(xhci, ctrl_ctx); in xhci_free_host_resources()
2314 struct xhci_input_control_ctx *ctrl_ctx) in xhci_finish_resource_reservation() argument
2318 num_dropped_eps = xhci_count_num_dropped_endpoints(xhci, ctrl_ctx); in xhci_finish_resource_reservation()
2805 struct xhci_input_control_ctx *ctrl_ctx; in xhci_reserve_bandwidth() local
2811 ctrl_ctx = xhci_get_input_control_ctx(in_ctx); in xhci_reserve_bandwidth()
2812 if (!ctrl_ctx) { in xhci_reserve_bandwidth()
2819 if (!EP_IS_ADDED(ctrl_ctx, i) && !EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2828 if (EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2837 xhci_update_bw_info(xhci, virt_dev->in_ctx, ctrl_ctx, virt_dev); in xhci_reserve_bandwidth()
2840 if (EP_IS_ADDED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2859 if (!EP_IS_ADDED(ctrl_ctx, i) && !EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2865 if (EP_IS_ADDED(ctrl_ctx, i)) { in xhci_reserve_bandwidth()
2877 if (EP_IS_DROPPED(ctrl_ctx, i)) in xhci_reserve_bandwidth()
2958 struct xhci_input_control_ctx *ctrl_ctx; in xhci_configure_endpoint() local
2974 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_configure_endpoint()
2975 if (!ctrl_ctx) { in xhci_configure_endpoint()
2983 xhci_reserve_host_resources(xhci, ctrl_ctx)) { in xhci_configure_endpoint()
2993 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
3001 trace_xhci_configure_endpoint_ctrl_ctx(ctrl_ctx); in xhci_configure_endpoint()
3014 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
3039 xhci_free_host_resources(xhci, ctrl_ctx); in xhci_configure_endpoint()
3041 xhci_finish_resource_reservation(xhci, ctrl_ctx); in xhci_configure_endpoint()
3077 struct xhci_input_control_ctx *ctrl_ctx; in xhci_check_bandwidth() local
3099 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_check_bandwidth()
3100 if (!ctrl_ctx) { in xhci_check_bandwidth()
3106 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_check_bandwidth()
3107 ctrl_ctx->add_flags &= cpu_to_le32(~EP0_FLAG); in xhci_check_bandwidth()
3108 ctrl_ctx->drop_flags &= cpu_to_le32(~(SLOT_FLAG | EP0_FLAG)); in xhci_check_bandwidth()
3111 if (ctrl_ctx->add_flags == cpu_to_le32(SLOT_FLAG) && in xhci_check_bandwidth()
3112 ctrl_ctx->drop_flags == 0) { in xhci_check_bandwidth()
3121 if ((virt_dev->eps[i-1].ring && !(ctrl_ctx->drop_flags & le32)) in xhci_check_bandwidth()
3122 || (ctrl_ctx->add_flags & le32) || i == 1) { in xhci_check_bandwidth()
3137 if ((le32_to_cpu(ctrl_ctx->drop_flags) & (1 << (i + 1))) && in xhci_check_bandwidth()
3138 !(le32_to_cpu(ctrl_ctx->add_flags) & (1 << (i + 1)))) { in xhci_check_bandwidth()
3234 struct xhci_input_control_ctx *ctrl_ctx, in xhci_setup_input_ctx_for_config_ep() argument
3237 ctrl_ctx->add_flags = cpu_to_le32(add_flags); in xhci_setup_input_ctx_for_config_ep()
3238 ctrl_ctx->drop_flags = cpu_to_le32(drop_flags); in xhci_setup_input_ctx_for_config_ep()
3240 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_setup_input_ctx_for_config_ep()
3305 struct xhci_input_control_ctx *ctrl_ctx; in xhci_endpoint_reset() local
3408 ctrl_ctx = xhci_get_input_control_ctx(cfg_cmd->in_ctx); in xhci_endpoint_reset()
3409 if (!ctrl_ctx) { in xhci_endpoint_reset()
3418 ctrl_ctx, ep_flag, ep_flag); in xhci_endpoint_reset()
3608 struct xhci_input_control_ctx *ctrl_ctx; in xhci_alloc_streams() local
3637 ctrl_ctx = xhci_get_input_control_ctx(config_cmd->in_ctx); in xhci_alloc_streams()
3638 if (!ctrl_ctx) { in xhci_alloc_streams()
3712 vdev->out_ctx, ctrl_ctx, in xhci_alloc_streams()
3775 struct xhci_input_control_ctx *ctrl_ctx; in xhci_free_streams() local
3798 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_free_streams()
3799 if (!ctrl_ctx) { in xhci_free_streams()
3820 vdev->out_ctx, ctrl_ctx, in xhci_free_streams()
4304 struct xhci_input_control_ctx *ctrl_ctx; in xhci_setup_device() local
4356 ctrl_ctx = xhci_get_input_control_ctx(virt_dev->in_ctx); in xhci_setup_device()
4357 if (!ctrl_ctx) { in xhci_setup_device()
4373 ctrl_ctx->add_flags = cpu_to_le32(SLOT_FLAG | EP0_FLAG); in xhci_setup_device()
4374 ctrl_ctx->drop_flags = 0; in xhci_setup_device()
4378 trace_xhci_address_ctrl_ctx(ctrl_ctx); in xhci_setup_device()
4461 ctrl_ctx->add_flags = 0; in xhci_setup_device()
4462 ctrl_ctx->drop_flags = 0; in xhci_setup_device()
4513 struct xhci_input_control_ctx *ctrl_ctx; in xhci_change_max_exit_latency() local
4539 ctrl_ctx = xhci_get_input_control_ctx(command->in_ctx); in xhci_change_max_exit_latency()
4540 if (!ctrl_ctx) { in xhci_change_max_exit_latency()
4551 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_change_max_exit_latency()
5251 struct xhci_input_control_ctx *ctrl_ctx; in xhci_update_hub_device() local
5271 ctrl_ctx = xhci_get_input_control_ctx(config_cmd->in_ctx); in xhci_update_hub_device()
5272 if (!ctrl_ctx) { in xhci_update_hub_device()
5289 ctrl_ctx->add_flags |= cpu_to_le32(SLOT_FLAG); in xhci_update_hub_device()