Re: [PATCH] JMicron JM20337 USB-SATA data corruption bugfix - device152d:2338

From: Alan Stern
Date: Thu Sep 04 2008 - 10:03:48 EST


On Thu, 4 Sep 2008, Thiago Galesi wrote:

> Ok, I looked into this a little bit further...
>
> K3B provides an interesting log:
>
> first, this is repeated 3 times:
>
> (K3bDevice::ScsiCommand) failed:
> command: MODE SELECT (55)
> errorcode: 70
> sense key: ILLEGAL REQUEST (5)
> asc: 26
> ascq: 0
>
> then it shows:
>
> (K3bDevice::ScsiCommand) failed:
> command: GET PERFORMANCE (ac)
> errorcode: 0
> sense key: NO SENSE (2)
> asc: 0
> ascq: 0
> (K3bDevice::Device) /dev/scd0: GET PERFORMANCE length det failed.
>
> And then all commands from then on fail
>
> strace indicate this is sent via SG_IO IOCTL (unfortunatelly, strace
> doen't show the contents in the ioctl)
>
> I don't know if the device is supposed to stop working when receiving
> an unkown command (like it is apparently doing), also because
> apparently cdrecord doesn't send this command but fails anyway

Who would ever design a device that was supposed to stop working when
it received an unknown command? Obviously there's a bug either in the
device or in the JMicron adapter.

What commands does cdrecord send and where does it fail?

Oh yes, one other thing... Have you tried hooking this drive directly
to an IDE cable (avoiding the USB-ATA adapter) to see if it works okay
in that environment? If it does then you know where the bug is.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/