if (eptr != from) {
switch (type_num) {
case 2:
- type = "cd";
+ type = "atapi";
break;
case 3:
type = "tape";
}
}
util_strlcpy(to, type, len);
-
return type_num;
}
udev_device_get_sysname(dev));
return 1;
}
+
if_class_num = strtoul(if_class, NULL, 16);
if (if_class_num == 8) {
+ /* mass storage */
if_subclass = udev_device_get_sysattr_value(dev_interface, "bInterfaceSubClass");
if (if_subclass != NULL)
protocol = set_usb_mass_storage_ifsubtype(type_str, if_subclass, sizeof(type_str)-1);
return 1;
}
- /* mass storage */
- if (protocol == 6 && !use_usb_info) {
+ /* mass storage : SCSI or ATAPI */
+ if ((protocol == 6 || protocol == 2) && !use_usb_info) {
struct udev_device *dev_scsi;
const char *scsi_model, *scsi_vendor, *scsi_type, *scsi_rev;
int host, bus, target, lun;
printf("Usage: usb_id [--usb-info] [--num-info] [--export] [--help] <devpath>\n"
" --usb-info use usb strings instead\n"
" --num-info use numerical values\n"
- " --export print values as environemt keys\n"
+ " --export print values as environment keys\n"
" --help print this help text\n\n");
default:
retval = 1;