Correct description of the return values of

the LibUSB v1.0 libusb_control_transfer() function.

PR:		usb/151851
Submitted by:	HIROSHI OOTA
Approved by:	thompsa (mentor)
This commit is contained in:
Hans Petter Selasky 2010-11-18 08:32:47 +00:00
parent ee597c8246
commit c865d740d5
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=215450

View File

@ -26,7 +26,7 @@
.\" .\"
.\" $FreeBSD$ .\" $FreeBSD$
.\" .\"
.Dd October 14, 2010 .Dd November 18, 2010
.Dt LIBUSB 3 .Dt LIBUSB 3
.Os .Os
.Sh NAME .Sh NAME
@ -380,10 +380,15 @@ LIBUSB_ERROR code on failure.
.Pp .Pp
.Ft int .Ft int
.Fn libusb_control_transfer "libusb_device_handle *devh" "uint8_t bmRequestType" "uint8_t bRequest" "uint16_t wValue" "uint16_t wIndex" "unsigned char *data" "uint16_t wLength" "unsigned int timeout" .Fn libusb_control_transfer "libusb_device_handle *devh" "uint8_t bmRequestType" "uint8_t bRequest" "uint16_t wValue" "uint16_t wIndex" "unsigned char *data" "uint16_t wLength" "unsigned int timeout"
Perform a USB control transfer. Returns 0 on success, LIBUSB_ERROR_TIMEOUT Perform a USB control transfer. Returns the actual number of bytes
if the transfer timeout, LIBUSB_ERROR_PIPE if the control request was not transferred on success in the range from and including zero until and
supported, LIBUSB_ERROR_NO_DEVICE if the device has been disconnected and including
LIBUSB_ERROR code on other failure. .Xa wLength .
On error a libusb error code is returned, for example
LIBUSB_ERROR_TIMEOUT if the transfer timeout, LIBUSB_ERROR_PIPE if the
control request was not supported, LIBUSB_ERROR_NO_DEVICE if the
device has been disconnected or another LIBUSB_ERROR code on other failures.
The libusb error codes are always negative.
. .
.Pp .Pp
.Ft int .Ft int