1// Copyright 2016 The Fuchsia Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#pragma once 6 7#include <zircon/hw/usb-hub.h> 8#include <zircon/types.h> 9#include <stdbool.h> 10 11typedef struct xhci xhci_t; 12 13zx_status_t xhci_enumerate_device(xhci_t* xhci, uint32_t hub_address, uint32_t port, 14 usb_speed_t speed); 15zx_status_t xhci_device_disconnected(xhci_t* xhci, uint32_t hub_address, uint32_t port); 16void xhci_start_device_thread(xhci_t* xhci); 17void xhci_stop_device_thread(xhci_t* xhci); 18zx_status_t xhci_queue_start_root_hubs(xhci_t* xhci); 19zx_status_t xhci_enable_endpoint(xhci_t* xhci, uint32_t slot_id, usb_endpoint_descriptor_t* ep_desc, 20 usb_ss_ep_comp_descriptor_t* ss_comp_desc, bool enable); 21zx_status_t xhci_configure_hub(xhci_t* xhci, uint32_t slot_id, usb_speed_t speed, 22 usb_hub_descriptor_t* descriptor); 23