diff --git a/drivers/usb/misc/usbtest.c b/drivers/usb/misc/usbtest.c
index d92b7ec9a230d370e1f74e470f3669ea1364ff72..eef370eb7a54d0ef814ddcaa2310b8837f086467 100644
--- a/drivers/usb/misc/usbtest.c
+++ b/drivers/usb/misc/usbtest.c
@@ -136,7 +136,7 @@ get_endpoints (struct usbtest_dev *dev, struct usb_interface *intf)
 					iso_out = e;
 			}
 		}
-		if ((in && out)  ||  (iso_in && iso_out))
+		if ((in && out)  ||  iso_in || iso_out)
 			goto found;
 	}
 	return -EINVAL;
@@ -162,6 +162,9 @@ get_endpoints (struct usbtest_dev *dev, struct usb_interface *intf)
 		dev->in_iso_pipe = usb_rcvisocpipe (udev,
 				iso_in->desc.bEndpointAddress
 					& USB_ENDPOINT_NUMBER_MASK);
+	}
+
+	if (iso_out) {
 		dev->iso_out = &iso_out->desc;
 		dev->out_iso_pipe = usb_sndisocpipe (udev,
 				iso_out->desc.bEndpointAddress