61 DBGC ( usbnet,
"USBNET %s could not open interrupt: %s\n",
69 DBGC ( usbnet,
"USBNET %s could not refill interrupt: %s\n",
78 DBGC ( usbnet,
"USBNET %s could not set alternate interface " 81 goto err_set_interface;
86 DBGC ( usbnet,
"USBNET %s could not open bulk IN: %s\n",
93 DBGC ( usbnet,
"USBNET %s could not open bulk OUT: %s\n",
100 DBGC ( usbnet,
"USBNET %s could not refill bulk IN: %s\n",
199 usbnet->
comms = comms;
200 DBGC ( usbnet,
"USBNET %s found communications interface %d\n",
205 DBGC ( usbnet,
"USBNET %s found no communications interface\n",
232 for ( alt = 0 ; ; alt++ ) {
256 DBGC ( usbnet,
"USBNET %s found data interface %d",
259 DBGC ( usbnet,
" using alternate %d", alt );
260 DBGC ( usbnet,
"\n" );
265 DBGC ( usbnet,
"USBNET %s found no data interface\n",
struct arbelprm_rc_send_wqe rc
unsigned int comms
Communications interface.
uint8_t interface[0]
List of interface numbers.
unsigned int count
Number of interfaces.
static int usbnet_comms_describe(struct usbnet_device *usbnet, struct usb_configuration_descriptor *config)
Describe communications interface and interrupt endpoint.
static int usbnet_data_describe(struct usbnet_device *usbnet, struct usb_configuration_descriptor *config)
Describe data interface and bulk endpoints.
uint64_t desc
Microcode descriptor list physical address.
#define ENOENT
No such file or directory.
unsigned int data
Data interface.
int usb_endpoint_open(struct usb_endpoint *ep)
Open USB endpoint.
#define USB_INTERRUPT_IN
Interrupt IN endpoint (internal) type.
void usb_endpoint_close(struct usb_endpoint *ep)
Close USB endpoint.
int usb_endpoint_described(struct usb_endpoint *ep, struct usb_configuration_descriptor *config, struct usb_interface_descriptor *interface, unsigned int type, unsigned int index)
Describe USB endpoint from device configuration.
struct usb_endpoint intr
Interrupt endpoint.
int usb_refill(struct usb_endpoint *ep)
Refill endpoint.
FILE_LICENCE(GPL2_OR_LATER_OR_UBDL)
static int usb_set_interface(struct usb_device *usb, unsigned int interface, unsigned int alternate)
Set USB interface alternate setting.
struct usb_endpoint out
Bulk OUT endpoint.
A USB interface descriptor.
#define USB_BULK_OUT
Bulk OUT endpoint (internal) type.
int usbnet_refill(struct usbnet_device *usbnet)
Refill USB network device bulk IN and interrupt endpoints.
struct usb_interface_descriptor * usb_interface_descriptor(struct usb_configuration_descriptor *config, unsigned int interface, unsigned int alternate)
Locate USB interface descriptor.
char * strerror(int errno)
Retrieve string representation of error number.
unsigned int alternate
Alternate setting for data interface.
struct usb_endpoint in
Bulk IN endpoint.
struct usb_device * usb
USB device.
#define USB_BULK_IN
Bulk IN endpoint (internal) type.
A USB configuration descriptor.
Universal Serial Bus (USB)
uint8_t data[48]
Additional event data.
struct usb_function_descriptor desc
Function descriptor.
int usbnet_describe(struct usbnet_device *usbnet, struct usb_configuration_descriptor *config)
Describe USB network device interfaces.
static int usbnet_has_intr(struct usbnet_device *usbnet)
Check if USB network device has an interrupt endpoint.
void usbnet_close(struct usbnet_device *usbnet)
Close USB network device.
struct usb_function * func
USB function.
int usbnet_open(struct usbnet_device *usbnet)
Open USB network device.