.\" This manpage has been automatically generated by docbook2man .\" from a DocBook document. This tool can be found at: .\" .\" Please send any bug reports, improvements, comments, patches, .\" etc. to Steve Cheng . .TH "USB_EPNUM_TO_EP_DESC" "" "06 October 2005" "" "" .SH NAME usb_epnum_to_ep_desc \- get the endpoint object with a given endpoint number .SH SYNOPSIS "SYNOPSIS" .sp \fB .sp struct usb_endpoint_descriptor * usb_epnum_to_ep_desc (struct usb_device * \fIdev\fB, unsigned \fIepnum\fB); \fR .SH "ARGUMENTS" .TP \fB\fIdev\fB\fR the device whose current configuration is considered .TP \fB\fIepnum\fB\fR the desired endpoint .SH "DESCRIPTION" .PP This walks the device descriptor for the currently active configuration, and returns a pointer to the endpoint with that particular endpoint number, or null. .PP Note that interface descriptors are not required to assign endpont numbers sequentially, so that it would be incorrect to assume that the first endpoint in that descriptor corresponds to interface zero. This routine helps device drivers avoid such mistakes.