X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=common%2Fusb.c;h=349e838f1d57785dff86eb5e8ee04d682d3841ec;hb=fef907b2e4406da8addebd7fefb6fd87ca7875ab;hp=b70f614d244f56a2ea2c29b007f45158dc92818c;hpb=9450ab2ba8d720bd9f73bccc0af2e2b5a2c2aaf1;p=oweals%2Fu-boot.git diff --git a/common/usb.c b/common/usb.c index b70f614d24..349e838f1d 100644 --- a/common/usb.c +++ b/common/usb.c @@ -28,6 +28,7 @@ #include #include #include +#include #include #include #include @@ -192,12 +193,15 @@ int usb_disable_asynch(int disable) */ /* - * submits an Interrupt Message + * submits an Interrupt Message. Some drivers may implement non-blocking + * polling: when non-block is true and the device is not responding return + * -EAGAIN instead of waiting for device to respond. */ -int usb_submit_int_msg(struct usb_device *dev, unsigned long pipe, - void *buffer, int transfer_len, int interval) +int usb_int_msg(struct usb_device *dev, unsigned long pipe, + void *buffer, int transfer_len, int interval, bool nonblock) { - return submit_int_msg(dev, pipe, buffer, transfer_len, interval); + return submit_int_msg(dev, pipe, buffer, transfer_len, interval, + nonblock); } /*