Home
last modified time | relevance | path

Searched refs:dev_name (Results 1 – 6 of 6) sorted by relevance

/system/core/toolbox/
Dlsusb.c148 static int lsusb_device_added(const char *dev_name, void *client_data) in lsusb_device_added() argument
150 struct usb_device *dev = usb_device_open(dev_name); in lsusb_device_added()
153 fprintf(stderr, "can't open device %s: %s\n", dev_name, strerror(errno)); in lsusb_device_added()
161 printf("%s:\n", dev_name); in lsusb_device_added()
178 printf("%s: %04x:%04x %s %s %s\n", dev_name, vid, pid, in lsusb_device_added()
191 static int lsusb_device_removed(const char *dev_name, void *client_data) in lsusb_device_removed() argument
/system/core/include/usbhost/
Dusbhost.h57 typedef int (* usb_device_added_cb)(const char *dev_name, void *client_data);
62 typedef int (* usb_device_removed_cb)(const char *dev_name, void *client_data);
104 struct usb_device *usb_device_open(const char *dev_name);
110 struct usb_device *usb_device_new(const char *dev_name, int fd);
/system/core/libusbhost/
Dusbhost.c74 char dev_name[64]; member
303 struct usb_device *usb_device_open(const char *dev_name) in usb_device_open() argument
307 D("usb_device_open %s\n", dev_name); in usb_device_open()
310 fd = open(dev_name, O_RDWR); in usb_device_open()
313 fd = open(dev_name, O_RDONLY); in usb_device_open()
325 D("[ usb open read-only %s fd = %d]\n", dev_name, fd); in usb_device_open()
328 struct usb_device* result = usb_device_new(dev_name, fd); in usb_device_open()
340 struct usb_device *usb_device_new(const char *dev_name, int fd) in usb_device_new() argument
345 D("usb_device_new %s fd: %d\n", dev_name, fd); in usb_device_new()
354 strncpy(device->dev_name, dev_name, sizeof(device->dev_name) - 1); in usb_device_new()
[all …]
/system/core/adb/
Dusb_windows.c69 int known_device(const char* dev_name);
73 int known_device_locked(const char* dev_name);
116 int known_device_locked(const char* dev_name) { in known_device_locked() argument
119 if (NULL != dev_name) { in known_device_locked()
124 (0 == stricmp(usb->interface_name, dev_name))) { in known_device_locked()
133 int known_device(const char* dev_name) { in known_device() argument
136 if (NULL != dev_name) { in known_device()
138 ret = known_device_locked(dev_name); in known_device()
Dusb_linux.c85 static int known_device(const char *dev_name) in known_device() argument
91 if(!strcmp(usb->fname, dev_name)) { in known_device()
119 static void register_device(const char *dev_name, const char *devpath,
560 static void register_device(const char *dev_name, const char *devpath, in register_device() argument
578 if(!strcmp(usb->fname, dev_name)) { in register_device()
586 dev_name, ep_in, ep_out, interface); in register_device()
588 strcpy(usb->fname, dev_name); in register_device()
/system/core/libdiskconfig/
Dconfig_mbr.c298 char *dev_name = NULL; in find_mbr_part() local
312 if (!(dev_name = malloc(MAX_NAME_LEN))) { in find_mbr_part()
317 num = snprintf(dev_name, MAX_NAME_LEN, "%s%d", dinfo->device, num); in find_mbr_part()
320 free(dev_name); in find_mbr_part()
324 return dev_name; in find_mbr_part()