Lines Matching refs:towrite
984 unsigned long towrite = 0; in ptp_write_func() local
998 towrite = size-curwrite; in ptp_write_func()
999 if (towrite > CONTEXT_BLOCK_SIZE) { in ptp_write_func()
1000 towrite = CONTEXT_BLOCK_SIZE; in ptp_write_func()
1003 if (towrite > ptp_usb->outep_maxpacket && towrite % ptp_usb->outep_maxpacket != 0) { in ptp_write_func()
1004 towrite -= towrite % ptp_usb->outep_maxpacket; in ptp_write_func()
1007 int getfunc_ret = handler->getfunc(NULL, handler->priv,towrite,bytes,&towrite); in ptp_write_func()
1012 while (usbwritten < towrite) { in ptp_write_func()
1016 towrite-usbwritten, in ptp_write_func()
1051 if (xwritten < towrite) /* short writes happen */ in ptp_write_func()
1061 if ((towrite % ptp_usb->outep_maxpacket) == 0) { in ptp_write_func()
1182 unsigned long towrite; in ptp_usb_sendreq() local
1198 towrite = PTP_USB_BULK_REQ_LEN-(sizeof(uint32_t)*(5-req->Nparam)); in ptp_usb_sendreq()
1199 ptp_init_send_memory_handler (&memhandler, (unsigned char*)&usbreq, towrite); in ptp_usb_sendreq()
1201 towrite, in ptp_usb_sendreq()
1210 if (written != towrite && ret != PTP_ERROR_CANCEL && ret != PTP_ERROR_IO) { in ptp_usb_sendreq()
1213 req->Code, written, towrite in ptp_usb_sendreq()