/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*/
#ifndef _WR_LIBUSB_H
#define _WR_LIBUSB_H
#ifdef __cplusplus
extern "C" {
#endif
/* debug levels */
#define DEBUG_NONE 0
/* consistent with the Makefile VER and mapfiles */
#define SUCCESS 0
/* default plugin dir */
#define USB_OPEN 0
char *sym_names[] = {
"usb_open", /* 0 */
"usb_close", /* 1 */
"usb_get_string", /* 2 */
"usb_get_string_simple", /* 3 */
"usb_get_descriptor_by_endpoint", /* 4 */
"usb_get_descriptor", /* 5 */
"usb_bulk_write", /* 6 */
"usb_bulk_read", /* 7 */
"usb_interrupt_write", /* 8 */
"usb_interrupt_read", /* 9 */
"usb_control_msg", /* 10 */
"usb_set_configuration", /* 11 */
"usb_claim_interface", /* 12 */
"usb_release_interface", /* 13 */
"usb_set_altinterface", /* 14 */
"usb_resetep", /* 15 */
"usb_clear_halt", /* 16 */
"usb_reset", /* 17 */
"usb_init", /* 18 */
"usb_set_debug", /* 19 */
"usb_find_busses", /* 20 */
"usb_find_devices", /* 21 */
"usb_device", /* 22 */
"usb_get_busses", /* 23 */
"usb_strerror", /* 24 */
"usb_busses", /* 25 */
"libusb_init", /* 26 */
"libusb_fini", /* 27 */
"libusb_version" /* 28 */
};
(struct usb_device *))
int, char *, size_t))
char *, size_t))
unsigned char, unsigned char, \
void *, int))
char, unsigned char, void *, int))
char *, int, int))
char *, int, int))
int, char *, int, int))
char *, int, int))
int, int, char *, int, int))
unsigned int))
unsigned int))
#define USB_INIT_CAST (void (*)(void))
#define USB_SET_DEBUG_CAST (void (*)(int))
#define USB_FIND_BUSSES_CAST (int (*)(void))
#define USB_FIND_DEVICES_CAST (int (*) (void))
(usb_dev_handle *))
#define USB_STRERROR_CAST (char *(*)(void))
#define LIBUSB_INIT_CAST (int (*)(void))
#define LIBUSB_FINI_CAST (int (*)(void))
sizeof (char *))
/*
* wrapper info structure - maintains wrapper state
* and plugins data
*/
typedef struct wrapper_info {
/*
* this is the dev_handles struct that each plugin
* maintains a linked list of
*/
typedef struct dev_handles {
/*
* plugin state info
*/
typedef struct plugin_info {
#ifdef __cplusplus
}
#endif
#endif /* _WR_LIBUSB_H */