iPXE
|
USB network devices. More...
Go to the source code of this file.
Functions | |
FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
int | usbnet_open (struct usbnet_device *usbnet) |
Open USB network device. More... | |
void | usbnet_close (struct usbnet_device *usbnet) |
Close USB network device. More... | |
int | usbnet_refill (struct usbnet_device *usbnet) |
Refill USB network device bulk IN and interrupt endpoints. More... | |
static int | usbnet_comms_describe (struct usbnet_device *usbnet, struct usb_configuration_descriptor *config) |
Describe communications interface and interrupt endpoint. More... | |
static int | usbnet_data_describe (struct usbnet_device *usbnet, struct usb_configuration_descriptor *config) |
Describe data interface and bulk endpoints. More... | |
int | usbnet_describe (struct usbnet_device *usbnet, struct usb_configuration_descriptor *config) |
Describe USB network device interfaces. More... | |
USB network devices.
USB network devices use a variety of packet formats and interface descriptors, but tend to have several features in common:
Definition in file usbnet.c.
FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
int usbnet_open | ( | struct usbnet_device * | usbnet | ) |
Open USB network device.
usbnet | USB network device |
rc | Return status code |
Definition at line 54 of file usbnet.c.
References usbnet_device::alternate, usbnet_device::data, DBGC, usbnet_device::func, usbnet_device::in, usbnet_device::intr, usb_function::name, usbnet_device::out, rc, strerror(), usb_function::usb, usb_endpoint_close(), usb_endpoint_open(), usb_refill(), usb_set_interface(), and usbnet_has_intr().
Referenced by acm_open(), axge_open(), dm96xx_open(), ecm_open(), imux_probe(), iphone_open(), lan78xx_open(), ncm_open(), smsc75xx_open(), and smsc95xx_open().
void usbnet_close | ( | struct usbnet_device * | usbnet | ) |
Close USB network device.
usbnet | USB network device |
Definition at line 127 of file usbnet.c.
References usbnet_device::alternate, usbnet_device::data, usbnet_device::func, usbnet_device::in, usbnet_device::intr, usbnet_device::out, usb_function::usb, usb_endpoint_close(), usb_set_interface(), and usbnet_has_intr().
Referenced by acm_close(), acm_open(), axge_close(), axge_open(), dm96xx_close(), dm96xx_open(), ecm_close(), ecm_open(), imux_shutdown(), iphone_close(), iphone_open(), lan78xx_close(), lan78xx_open(), ncm_close(), ncm_open(), smsc75xx_close(), smsc75xx_open(), smsc95xx_close(), and smsc95xx_open().
int usbnet_refill | ( | struct usbnet_device * | usbnet | ) |
Refill USB network device bulk IN and interrupt endpoints.
usbnet | USB network device |
rc | Return status code |
Definition at line 151 of file usbnet.c.
References usbnet_device::in, usbnet_device::intr, rc, usb_refill(), and usbnet_has_intr().
Referenced by acm_poll(), axge_poll(), dm96xx_poll(), ecm_poll(), imux_step(), iphone_poll(), ncm_poll(), smsc75xx_poll(), and smsc95xx_poll().
|
static |
Describe communications interface and interrupt endpoint.
usbnet | USB network device |
config | Configuration descriptor |
rc | Return status code |
Definition at line 174 of file usbnet.c.
References usbnet_device::comms, usb_function_descriptor::count, DBGC, usb_function::desc, ENOENT, usbnet_device::func, usb_function::interface, usbnet_device::intr, usb_function::name, rc, usb_endpoint_described(), usb_interface_descriptor(), and USB_INTERRUPT_IN.
Referenced by usbnet_describe().
|
static |
Describe data interface and bulk endpoints.
usbnet | USB network device |
config | Configuration descriptor |
rc | Return status code |
Definition at line 217 of file usbnet.c.
References usbnet_device::alternate, usb_function_descriptor::count, data, usbnet_device::data, DBGC, usb_function::desc, ENOENT, usbnet_device::func, usbnet_device::in, usb_function::interface, usb_function::name, usbnet_device::out, rc, USB_BULK_IN, USB_BULK_OUT, usb_endpoint_described(), and usb_interface_descriptor().
Referenced by usbnet_describe().
int usbnet_describe | ( | struct usbnet_device * | usbnet, |
struct usb_configuration_descriptor * | config | ||
) |
Describe USB network device interfaces.
usbnet | USB network device |
config | Configuration descriptor |
rc | Return status code |
Definition at line 277 of file usbnet.c.
References rc, usbnet_comms_describe(), usbnet_data_describe(), and usbnet_has_intr().
Referenced by acm_probe(), axge_probe(), dm96xx_probe(), ecm_probe(), imux_probe(), iphone_probe(), lan78xx_probe(), ncm_probe(), smsc75xx_probe(), and smsc95xx_probe().