]> git.neil.brown.name Git - history.git/commitdiff
[PATCH] Documentation in usb.c
authorJohann Deneux <johann.deneux@laposte.net>
Tue, 28 May 2002 07:42:20 +0000 (00:42 -0700)
committerGreg Kroah-Hartman <greg@kroah.com>
Tue, 28 May 2002 07:42:20 +0000 (00:42 -0700)
It seems to me that code and comments disagree in drivers/usr/core/usb.c.

I attached a patch fixing the comments. Hopefully the code is right :)
This patch is against 2.5.16

drivers/usb/core/usb.c

index 236dc99bb333fa01f6db8be21f21350d2c604615..4fcd2a04a673c063389b9b833af93930a38b2175 100644 (file)
@@ -2032,8 +2032,8 @@ int usb_set_address(struct usb_device *dev)
  *
  * This call is synchronous, and may not be used in an interrupt context.
  *
- * Returns zero on success, or else the status code returned by the
- * underlying usb_control_msg() call.
+ * Returns the number of bytes received on success, or else the status code
+ * returned by the underlying usb_control_msg() call.
  */
 int usb_get_descriptor(struct usb_device *dev, unsigned char type, unsigned char index, void *buf, int size)
 {
@@ -2073,8 +2073,8 @@ int usb_get_descriptor(struct usb_device *dev, unsigned char type, unsigned char
  *
  * This call is synchronous, and may not be used in an interrupt context.
  *
- * Returns zero on success, or else the status code returned by the
- * underlying usb_control_msg() call.
+ * Returns the number of bytes received on success, or else the status code
+ * returned by the underlying usb_control_msg() call.
  */
 int usb_get_string(struct usb_device *dev, unsigned short langid, unsigned char index, void *buf, int size)
 {
@@ -2100,8 +2100,8 @@ int usb_get_string(struct usb_device *dev, unsigned short langid, unsigned char
  *
  * This call is synchronous, and may not be used in an interrupt context.
  *
- * Returns zero on success, or else the status code returned by the
- * underlying usb_control_msg() call.
+ * Returns the number of bytes received on success, or else the status code
+ * returned by the underlying usb_control_msg() call.
  */
 int usb_get_device_descriptor(struct usb_device *dev)
 {
@@ -2135,8 +2135,8 @@ int usb_get_device_descriptor(struct usb_device *dev)
  *
  * This call is synchronous, and may not be used in an interrupt context.
  *
- * Returns zero on success, or else the status code returned by the
- * underlying usb_control_msg() call.
+ * Returns the number of bytes received on success, or else the status code
+ * returned by the underlying usb_control_msg() call.
  */
 int usb_get_status(struct usb_device *dev, int type, int target, void *data)
 {