10Sstevel@tonic-gate /* 20Sstevel@tonic-gate * CDDL HEADER START 30Sstevel@tonic-gate * 40Sstevel@tonic-gate * The contents of this file are subject to the terms of the 5*5773Sqz150045 * Common Development and Distribution License (the "License"). 6*5773Sqz150045 * You may not use this file except in compliance with the License. 70Sstevel@tonic-gate * 80Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 90Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 100Sstevel@tonic-gate * See the License for the specific language governing permissions 110Sstevel@tonic-gate * and limitations under the License. 120Sstevel@tonic-gate * 130Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 140Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 150Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 160Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 170Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 180Sstevel@tonic-gate * 190Sstevel@tonic-gate * CDDL HEADER END 200Sstevel@tonic-gate */ 210Sstevel@tonic-gate /* 22*5773Sqz150045 * Copyright 2008 Sun Microsystems, Inc. All rights reserved. 230Sstevel@tonic-gate * Use is subject to license terms. 240Sstevel@tonic-gate */ 250Sstevel@tonic-gate 260Sstevel@tonic-gate #ifndef _SYS_USB_UHCITGT_H 270Sstevel@tonic-gate #define _SYS_USB_UHCITGT_H 280Sstevel@tonic-gate 290Sstevel@tonic-gate 300Sstevel@tonic-gate #ifdef __cplusplus 310Sstevel@tonic-gate extern "C" { 320Sstevel@tonic-gate #endif 330Sstevel@tonic-gate 340Sstevel@tonic-gate /* 350Sstevel@tonic-gate * Shared function declarations 360Sstevel@tonic-gate */ 370Sstevel@tonic-gate queue_head_t *uhci_alloc_queue_head(uhci_state_t *uhcip); 380Sstevel@tonic-gate uhci_state_t *uhci_obtain_state(dev_info_t *dip); 390Sstevel@tonic-gate 400Sstevel@tonic-gate int uhci_insert_ctrl_td(uhci_state_t *uhcip, 410Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle, 420Sstevel@tonic-gate usb_ctrl_req_t *req, 430Sstevel@tonic-gate usb_flags_t flags); 440Sstevel@tonic-gate int uhci_insert_bulk_td(uhci_state_t *uhcip, 450Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle, 460Sstevel@tonic-gate usb_bulk_req_t *req, 470Sstevel@tonic-gate usb_flags_t flags); 480Sstevel@tonic-gate int uhci_insert_intr_td(uhci_state_t *uhcip, 490Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle, 500Sstevel@tonic-gate usb_intr_req_t *req, 510Sstevel@tonic-gate usb_flags_t flags); 520Sstevel@tonic-gate int uhci_insert_isoc_td( 530Sstevel@tonic-gate uhci_state_t *uhcip, 540Sstevel@tonic-gate usba_pipe_handle_data_t *ph, 550Sstevel@tonic-gate usb_isoc_req_t *isoc_req, 560Sstevel@tonic-gate size_t length, 570Sstevel@tonic-gate usb_flags_t usb_flags); 580Sstevel@tonic-gate 590Sstevel@tonic-gate void uhci_remove_qh(uhci_state_t *uhcip, uhci_pipe_private_t *pp); 600Sstevel@tonic-gate void uhci_insert_qh(uhci_state_t *uhcip, 610Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle); 620Sstevel@tonic-gate void uhci_modify_td_active_bits( 630Sstevel@tonic-gate uhci_state_t *uhcip, 640Sstevel@tonic-gate uhci_pipe_private_t *pp); 650Sstevel@tonic-gate 660Sstevel@tonic-gate int uhci_allocate_bandwidth(uhci_state_t *uhcip, 670Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle, uint_t *node); 680Sstevel@tonic-gate void uhci_deallocate_bandwidth(uhci_state_t *uhcip, 690Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle); 700Sstevel@tonic-gate void uhci_remove_tds_tws(uhci_state_t *uhcip, 710Sstevel@tonic-gate usba_pipe_handle_data_t *ph); 720Sstevel@tonic-gate void uhci_remove_isoc_tds_tws(uhci_state_t *uhcip, 730Sstevel@tonic-gate uhci_pipe_private_t *ph); 740Sstevel@tonic-gate int uhci_start_isoc_receive_polling( 750Sstevel@tonic-gate uhci_state_t *uhcip, 760Sstevel@tonic-gate usba_pipe_handle_data_t *ph, 770Sstevel@tonic-gate usb_isoc_req_t *req, 780Sstevel@tonic-gate usb_flags_t usb_flags); 790Sstevel@tonic-gate 800Sstevel@tonic-gate 810Sstevel@tonic-gate void uhci_save_data_toggle(uhci_pipe_private_t *pp); 820Sstevel@tonic-gate int uhci_handle_root_hub_request( 830Sstevel@tonic-gate uhci_state_t *uhcip, 840Sstevel@tonic-gate usba_pipe_handle_data_t *pipe_handle, 850Sstevel@tonic-gate usb_ctrl_req_t *req); 860Sstevel@tonic-gate 870Sstevel@tonic-gate void uhci_remove_bulk_tds_tws(uhci_state_t *uhcip, 880Sstevel@tonic-gate uhci_pipe_private_t *pp, 890Sstevel@tonic-gate int what); 900Sstevel@tonic-gate void uhci_root_hub_reset_occurred(uhci_state_t *uhcip, 910Sstevel@tonic-gate usb_port_t port); 920Sstevel@tonic-gate int uhci_root_hub_allocate_intr_pipe_resource( 930Sstevel@tonic-gate uhci_state_t *uhcip, 940Sstevel@tonic-gate usb_flags_t flags); 950Sstevel@tonic-gate void uhci_root_hub_intr_pipe_cleanup(uhci_state_t *uhcip, 960Sstevel@tonic-gate usb_cr_t cr); 970Sstevel@tonic-gate void uhci_hcdi_callback(uhci_state_t *uhcip, 980Sstevel@tonic-gate uhci_pipe_private_t *pp, 990Sstevel@tonic-gate usba_pipe_handle_data_t *ph, 1000Sstevel@tonic-gate uhci_trans_wrapper_t *tw, 1010Sstevel@tonic-gate usb_cr_t cr); 1020Sstevel@tonic-gate int uhci_allocate_periodic_in_resource(uhci_state_t *uhcip, 1030Sstevel@tonic-gate uhci_pipe_private_t *pp, 1040Sstevel@tonic-gate uhci_trans_wrapper_t *tw, usb_flags_t flags); 1050Sstevel@tonic-gate 1060Sstevel@tonic-gate #ifdef __cplusplus 1070Sstevel@tonic-gate } 1080Sstevel@tonic-gate #endif 1090Sstevel@tonic-gate 1100Sstevel@tonic-gate #endif /* _SYS_USB_UHCITGT_H */ 111