|
|
@@ -386,12 +386,18 @@ void *usb_resource_thread(void *userdata);
|
|
|
#define usb_read(cgpu, buf, bufsiz, read, cmd) \
|
|
|
_usb_read(cgpu, DEFAULT_INTINFO, DEFAULT_EP_IN, buf, bufsiz, read, DEVTIMEOUT, NULL, cmd, false)
|
|
|
|
|
|
+#define usb_read_ii(cgpu, intinfo, buf, bufsiz, read, cmd) \
|
|
|
+ _usb_read(cgpu, intinfo, DEFAULT_EP_IN, buf, bufsiz, read, DEVTIMEOUT, NULL, cmd, false)
|
|
|
+
|
|
|
#define usb_read_once(cgpu, buf, bufsiz, read, cmd) \
|
|
|
_usb_read(cgpu, DEFAULT_INTINFO, DEFAULT_EP_IN, buf, bufsiz, read, DEVTIMEOUT, NULL, cmd, true)
|
|
|
|
|
|
#define usb_read_once_timeout(cgpu, buf, bufsiz, read, timeout, cmd) \
|
|
|
_usb_read(cgpu, DEFAULT_INTINFO, DEFAULT_EP_IN, buf, bufsiz, read, timeout, NULL, cmd, true)
|
|
|
|
|
|
+#define usb_read_ii_once_timeout(cgpu, intinfo, buf, bufsiz, read, timeout, cmd) \
|
|
|
+ _usb_read(cgpu, intinfo, DEFAULT_EP_IN, buf, bufsiz, read, timeout, NULL, cmd, true)
|
|
|
+
|
|
|
#define usb_read_nl(cgpu, buf, bufsiz, read, cmd) \
|
|
|
_usb_read(cgpu, DEFAULT_INTINFO, DEFAULT_EP_IN, buf, bufsiz, read, DEVTIMEOUT, "\n", cmd, false)
|
|
|
|