Non-BCD bcdDevice values

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Some devices have a non-BCD value in bcdDevice. For example some card readers based on an ICSI chip have bcdDevice 0x016F. (They put "1.6F" in bytes 32-35 of their INQUIRY data.)

For devices which need US_FL_FIX_INQUIRY, fill_inquiry_response() doesn't appear to handle non-BCD values correctly since it just adds 0x30 to each 4-bit value:
		data[32] = 0x30 + ((bcdDevice>>12) & 0x0F);
		data[33] = 0x30 + ((bcdDevice>>8) & 0x0F);
		data[34] = 0x30 + ((bcdDevice>>4) & 0x0F);
		data[35] = 0x30 + ((bcdDevice) & 0x0F);

Thus hex 0xA to 0xF correspond to : ; < = > ? characters. For the 0x016F example, that would appear as "016?" in the generated INQUIRY data.

Is it worth submitting a patch to fix that? Do any devices which need US_FL_FIX_INQUIRY have non-BCD bcdDevice values?
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux