]> git.sur5r.net Git - u-boot/blobdiff - drivers/usb/gadget/ether.c
Merge branch 'master' of git://git.denx.de/u-boot-mpc5xxx
[u-boot] / drivers / usb / gadget / ether.c
index 1e187e5b5261adbcdffcc30670438e9df7ed59dc..de880ffeb8a6e9c1821ce88ada68134f214fa410 100644 (file)
@@ -24,7 +24,6 @@
 #include <asm/errno.h>
 #include <linux/netdevice.h>
 #include <linux/usb/ch9.h>
-#include <usbdescriptors.h>
 #include <linux/usb/cdc.h>
 #include <linux/usb/gadget.h>
 #include <net.h>
@@ -1978,8 +1977,8 @@ static int is_eth_addr_valid(char *str)
                        p = q;
                }
 
-               if (i == 6) /* it looks ok */
-                       return 1;
+               /* Now check the contents. */
+               return is_valid_ether_addr(ea);
        }
        return 0;
 }