Lines Matching refs:dev_name
74 char dev_name[64];
303 struct usb_device *usb_device_open(const char *dev_name)
307 D("usb_device_open %s\n", dev_name);
310 fd = open(dev_name, O_RDWR);
313 fd = open(dev_name, O_RDONLY);
325 D("[ usb open read-only %s fd = %d]\n", dev_name, fd);
328 struct usb_device* result = usb_device_new(dev_name, fd);
340 struct usb_device *usb_device_new(const char *dev_name, int fd)
345 D("usb_device_new %s fd: %d\n", dev_name, fd);
354 strncpy(device->dev_name, dev_name, sizeof(device->dev_name) - 1);
372 int fd = open(device->dev_name, O_RDWR);
392 return device->dev_name;
398 sscanf(device->dev_name, USB_FS_ID_SCANNER, &bus, &dev);