Lines Matching refs:res
314 int res; in usb_bulk_write() local
329 res = -1; in usb_bulk_write()
333 res = ioctl(h->desc, USBDEVFS_SUBMITURB, urb); in usb_bulk_write()
334 } while((res < 0) && (errno == EINTR)); in usb_bulk_write()
336 if(res < 0) { in usb_bulk_write()
340 res = -1; in usb_bulk_write()
347 res = pthread_cond_timedwait(&h->notify, &h->lock, &ts); in usb_bulk_write()
348 if(res < 0 || h->dead) { in usb_bulk_write()
353 res = urb->actual_length; in usb_bulk_write()
361 return res; in usb_bulk_write()
368 int res; in usb_bulk_read() local
380 res = -1; in usb_bulk_read()
384 res = ioctl(h->desc, USBDEVFS_SUBMITURB, urb); in usb_bulk_read()
385 } while((res < 0) && (errno == EINTR)); in usb_bulk_read()
387 if(res < 0) { in usb_bulk_read()
396 res = ioctl(h->desc, USBDEVFS_REAPURB, &out); in usb_bulk_read()
401 res = -1; in usb_bulk_read()
404 if(res < 0) { in usb_bulk_read()
418 res = urb->actual_length; in usb_bulk_read()
420 res = -1; in usb_bulk_read()
432 return res; in usb_bulk_read()