Searched refs:usb_handle (Results 1 - 17 of 17) sorted by relevance

/system/core/fastboot/
H A Dusb.h36 typedef struct usb_handle usb_handle; typedef in typeref:struct:usb_handle
65 usb_handle *usb_open(ifc_match_func callback);
66 int usb_close(usb_handle *h);
67 int usb_read(usb_handle *h, void *_data, int len);
68 int usb_write(usb_handle *h, const void *_data, int len);
69 int usb_wait_for_disconnect(usb_handle *h);
H A Dfastboot.h41 int fb_command(usb_handle *usb, const char *cmd);
42 int fb_command_response(usb_handle *usb, const char *cmd, char *response);
43 int fb_download_data(usb_handle *usb, const void *data, unsigned size);
44 int fb_download_data_sparse(usb_handle *usb, struct sparse_file *s);
51 int fb_getvar(struct usb_handle *usb, char *response, const char *fmt, ...);
52 int fb_format_supported(usb_handle *usb, const char *partition, const char *type_override);
66 int fb_execute_queue(usb_handle *usb);
H A Dusb_windows.c48 /** Structure usb_handle describes our connection to the usb device via
52 struct usb_handle { struct
71 int recognized_device(usb_handle* handle, ifc_match_func callback);
74 usb_handle* do_usb_open(const wchar_t* interface_name);
77 int usb_write(usb_handle* handle, const void* data, int len);
80 int usb_read(usb_handle *handle, void* data, int len);
83 void usb_cleanup_handle(usb_handle* handle);
86 void usb_kick(usb_handle* handle);
89 int usb_close(usb_handle* handle);
92 usb_handle* do_usb_ope
[all...]
H A Dprotocol.c50 static int check_response(usb_handle *usb, unsigned int size, char *response)
109 static int _command_start(usb_handle *usb, const char *cmd, unsigned size,
132 static int _command_data(usb_handle *usb, const void *data, unsigned size)
151 static int _command_end(usb_handle *usb)
161 static int _command_send(usb_handle *usb, const char *cmd,
188 static int _command_send_no_data(usb_handle *usb, const char *cmd,
194 int fb_command(usb_handle *usb, const char *cmd)
199 int fb_command_response(usb_handle *usb, const char *cmd, char *response)
204 int fb_download_data(usb_handle *usb, const void *data, unsigned size)
226 usb_handle *us
[all...]
H A Dusb_osx.c53 struct usb_handle struct
67 static int try_interfaces(IOUSBDeviceInterface182 **dev, usb_handle *handle) {
260 static int try_device(io_service_t device, usb_handle *handle) {
382 static int init_usb(ifc_match_func callback, usb_handle **handle) {
387 usb_handle h;
435 *handle = calloc(1, sizeof(usb_handle));
436 memcpy(*handle, &h, sizeof(usb_handle));
455 usb_handle *usb_open(ifc_match_func callback) {
456 usb_handle *handle = NULL;
466 int usb_close(usb_handle *
[all...]
H A Dusb_linux.c77 struct usb_handle struct
308 static usb_handle *find_usb_device(const char *base, ifc_match_func callback)
310 usb_handle *usb = 0;
343 usb = calloc(1, sizeof(usb_handle));
366 int usb_write(usb_handle *h, const void *_data, int len)
401 int usb_read(usb_handle *h, void *_data, int len)
446 void usb_kick(usb_handle *h)
458 int usb_close(usb_handle *h)
472 usb_handle *usb_open(ifc_match_func callback)
481 int usb_wait_for_disconnect(usb_handle *us
[all...]
H A Dusbtest.c89 int test_null(usb_handle *usb)
108 int test_zero(usb_handle *usb)
130 int (*test)(usb_handle *usb);
180 usb_handle *usb;
H A Dfastboot.cpp246 usb_handle *open_device(void)
248 static usb_handle *usb = 0;
598 static int64_t get_target_sparse_limit(struct usb_handle *usb)
615 static int64_t get_sparse_limit(struct usb_handle *usb, int64_t size)
645 static int needs_erase(usb_handle* usb, const char *part)
653 static int load_buf_fd(usb_handle *usb, int fd,
687 static int load_buf(usb_handle *usb, const char *fname,
720 void do_flash(usb_handle *usb, const char *pname, const char *fname)
739 void do_update(usb_handle *usb, const char *filename, int erase_first)
805 void do_flashall(usb_handle *us
[all...]
H A Dengine.c87 int fb_getvar(struct usb_handle *usb, char *response, const char *fmt, ...)
109 int fb_format_supported(usb_handle *usb, const char *partition, const char *type_override)
367 int fb_execute_queue(usb_handle *usb)
/system/core/adb/
H A Dusb_windows.cpp33 /** Structure usb_handle describes our connection to the usb device via
37 struct usb_handle { struct
39 usb_handle *prev;
42 usb_handle *next;
64 static usb_handle handle_list = {
80 int register_new_device(usb_handle* handle);
83 int recognized_device(usb_handle* handle);
100 usb_handle* do_usb_open(const wchar_t* interface_name);
103 int usb_write(usb_handle* handle, const void* data, int len);
106 int usb_read(usb_handle *handl
[all...]
H A Dusb_linux_client.cpp43 struct usb_handle struct
48 int (*write)(usb_handle *h, const void *data, int len);
49 int (*read)(usb_handle *h, void *data, int len);
50 void (*kick)(usb_handle *h);
209 struct usb_handle *usb = (struct usb_handle *)x;
244 static int usb_adb_write(usb_handle *h, const void *data, int len)
259 static int usb_adb_read(usb_handle *h, void *data, int len)
274 static void usb_adb_kick(usb_handle *h)
288 usb_handle*
[all...]
H A Dtransport.h47 void register_usb_transport(usb_handle* h, const char* serial,
54 void unregister_usb_transport(usb_handle* usb);
H A Dusb_osx.cpp40 struct usb_handle struct
58 static usb_handle* CheckInterface(IOUSBInterfaceInterface **iface,
255 usb_handle* handle = CheckInterface((IOUSBInterfaceInterface**)iface,
285 usb_handle *handle = (usb_handle *)refCon;
300 static usb_handle*
303 usb_handle* handle = NULL;
338 handle = reinterpret_cast<usb_handle*>(calloc(1, sizeof(usb_handle)));
438 int usb_write(usb_handle *handl
[all...]
H A Dadb.h47 struct usb_handle;
193 usb_handle *usb;
269 void init_usb_transport(atransport *t, usb_handle *usb, int state);
328 int usb_write(usb_handle *h, const void *data, int len);
329 int usb_read(usb_handle *h, void *data, int len);
330 int usb_close(usb_handle *h);
331 void usb_kick(usb_handle *h);
H A Dusb_linux.cpp48 struct usb_handle struct
50 usb_handle *prev;
51 usb_handle *next;
78 static usb_handle handle_list = {
85 usb_handle *usb;
102 usb_handle *usb;
317 static int usb_bulk_write(usb_handle *h, const void *data, int len)
370 static int usb_bulk_read(usb_handle *h, void *data, int len)
444 int usb_write(usb_handle *h, const void *_data, int len)
484 int usb_read(usb_handle *
[all...]
H A Dtransport_usb.cpp83 void init_usb_transport(atransport *t, usb_handle *h, int state)
H A Dtransport.cpp1020 void register_usb_transport(usb_handle *usb, const char *serial, const char *devpath, unsigned writeable)
1024 D("transport: %p init'ing for usb_handle %p (sn='%s')\n", t, usb,
1045 void unregister_usb_transport(usb_handle *usb)

Completed in 150 milliseconds