summaryrefslogtreecommitdiffstats
path: root/kernel/tools/usb
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/tools/usb')
-rw-r--r--kernel/tools/usb/testusb.c10
-rw-r--r--kernel/tools/usb/usbip/src/usbip_detach.c4
2 files changed, 8 insertions, 6 deletions
diff --git a/kernel/tools/usb/testusb.c b/kernel/tools/usb/testusb.c
index 879f9870a..0692d99b6 100644
--- a/kernel/tools/usb/testusb.c
+++ b/kernel/tools/usb/testusb.c
@@ -394,7 +394,7 @@ int main (int argc, char **argv)
* low speed, interrupt 8 * 1 = 8
*/
param.iterations = 1000;
- param.length = 512;
+ param.length = 1024;
param.vary = 512;
param.sglen = 32;
@@ -454,10 +454,10 @@ usage:
"\t-t testnum only run specified case\n"
"\t-n no test running, show devices to be tested\n"
"Case arguments:\n"
- "\t-c iterations default 1000\n"
- "\t-s packetsize default 512\n"
- "\t-g sglen default 32\n"
- "\t-v vary default 512\n",
+ "\t-c iterations default 1000\n"
+ "\t-s transfer length default 1024\n"
+ "\t-g sglen default 32\n"
+ "\t-v vary default 512\n",
argv[0]);
return 1;
}
diff --git a/kernel/tools/usb/usbip/src/usbip_detach.c b/kernel/tools/usb/usbip/src/usbip_detach.c
index 05c6d1585..9db9d21bb 100644
--- a/kernel/tools/usb/usbip/src/usbip_detach.c
+++ b/kernel/tools/usb/usbip/src/usbip_detach.c
@@ -47,7 +47,9 @@ static int detach_port(char *port)
uint8_t portnum;
char path[PATH_MAX+1];
- for (unsigned int i = 0; i < strlen(port); i++)
+ unsigned int port_len = strlen(port);
+
+ for (unsigned int i = 0; i < port_len; i++)
if (!isdigit(port[i])) {
err("invalid port %s", port);
return -1;