ChangeSet 1.1843.4.27, 2004/08/25 10:25:30-07:00, [EMAIL PROTECTED]

[PATCH] USB: ethernet gadget, minor fixes

Minor tweaks to the ethernet gadget driver:

 - mention that it requires full-duplex hardware
 - correct the string description:  they're always UTF-8
 - fix minor C error: don't "&array" (Al Borchers)

Signed-off-by: David Brownell <[EMAIL PROTECTED]>
Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>


 drivers/usb/gadget/ether.c |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)


diff -Nru a/drivers/usb/gadget/ether.c b/drivers/usb/gadget/ether.c
--- a/drivers/usb/gadget/ether.c        2004-08-26 16:41:14 -07:00
+++ b/drivers/usb/gadget/ether.c        2004-08-26 16:41:14 -07:00
@@ -63,6 +63,7 @@
 
 /*
  * Ethernet gadget driver -- with CDC and non-CDC options
+ * Builds on hardware support for a full duplex link.
  *
  * CDC Ethernet is the standard USB solution for sending Ethernet frames
  * using USB.  Real hardware tends to use the same framing protocol but look
@@ -859,7 +860,7 @@
 static char                            ethaddr [2 * ETH_ALEN + 1];
 #endif
 
-/* static strings, in iso 8859/1 */
+/* static strings, in UTF-8 */
 static struct usb_string               strings [] = {
        { STRING_MANUFACTURER,  manufacturer, },
        { STRING_PRODUCT,       product_desc, },
@@ -901,9 +902,9 @@
 
        if (type == USB_DT_OTHER_SPEED_CONFIG)
                hs = !hs;
-#define which_fn(t)    (hs ? & hs_ ## t ## _function : & fs_ ## t ## _function)
+#define which_fn(t)    (hs ? hs_ ## t ## _function : fs_ ## t ## _function)
 #else
-#define        which_fn(t)     (& fs_ ## t ## _function)
+#define        which_fn(t)     (fs_ ## t ## _function)
 #endif
 
        if (index >= device_desc.bNumConfigurations)
@@ -915,14 +916,12 @@
         */
        if (device_desc.bNumConfigurations == 2 && index == 0) {
                config = &rndis_config;
-               function = (const struct usb_descriptor_header **)
-                               which_fn (rndis);
+               function = which_fn (rndis);
        } else
 #endif
        {
                config = &eth_config;
-               function = (const struct usb_descriptor_header **)
-                               which_fn (eth);
+               function = which_fn (eth);
        }
 
        /* for now, don't advertise srp-only devices */



-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

Reply via email to