Lines Matching refs:t
49 static int remote_read(apacket *p, atransport *t) in remote_read() argument
51 if(usb_read(t->usb, &p->msg, sizeof(amessage))){ in remote_read()
64 if(usb_read(t->usb, p->data, p->msg.data_length)){ in remote_read()
78 static int remote_write(apacket *p, atransport *t) in remote_write() argument
84 if(usb_write(t->usb, &p->msg, sizeof(amessage))) { in remote_write()
89 if(usb_write(t->usb, &p->data, size)) { in remote_write()
97 static void remote_close(atransport *t) in remote_close() argument
99 usb_close(t->usb); in remote_close()
100 t->usb = 0; in remote_close()
103 static void remote_kick(atransport *t) in remote_kick() argument
105 usb_kick(t->usb); in remote_kick()
108 void init_usb_transport(atransport *t, usb_handle *h, int state) in init_usb_transport() argument
111 t->close = remote_close; in init_usb_transport()
112 t->kick = remote_kick; in init_usb_transport()
113 t->read_from_remote = remote_read; in init_usb_transport()
114 t->write_to_remote = remote_write; in init_usb_transport()
115 t->sync_token = 1; in init_usb_transport()
116 t->connection_state = state; in init_usb_transport()
117 t->type = kTransportUsb; in init_usb_transport()
118 t->usb = h; in init_usb_transport()