Skip to contentSkip to conversation

usb-storage data transfer anomaly

DISCUSSION Bajo, Allison 2 participants 2 messages Mar 21, 2002

lore
Share & tools
lore
#0 lore raw

I was debugging 2.4.19-pre3 using a SanDisk SDDR-31 CF Card Reader when I observed the following behavior:

1. The device (SDDR-31) was intermittently disconnected by the hub and then reconnected even though the device was present all the time. The trigger for this event was plugging in a CF card into the reader.

2. As a result of (1), I receive a CSW from a previous CBW before the disconnect and reconnect in (1).

3. When usb_stor_Bulk_transport ( ) returns with a USB_STOR_TRANPORT_ERROR, usb_stor_invoke_transport ( ) tries to reset the device but fails on the reset.

4. Any subsequent CBW and CSW pair will be skewed. The CBW will receive the CSW of a previous CBW. At this point it is not recoverable except a reboot.

Example traffic:

	CBW 0
	CSW 0

	Disconnect
	Reconnect

	CBW 1
	CSW 0

	CBW 2
	CSW 1

	...

I think you get the picture. Any ideas.

- Allison B

_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

#1 lore raw

One idea.... get a different setup.

The device is likely disconnecting because the hub is killing power due to over-current. Which is bogus -- I have one of these devices, and I know their current draw is legit.

Is the hub powered? Likely that's what you need.

Matt

Quoted 35 lines · Allison

I was debugging 2.4.19-pre3 using a SanDisk SDDR-31 CF Card Reader when I observed the following behavior:

1. The device (SDDR-31) was intermittently disconnected by the hub and then reconnected even though the device was present all the time. The trigger for this event was plugging in a CF card into the reader.

2. As a result of (1), I receive a CSW from a previous CBW before the disconnect and reconnect in (1).

3. When usb_stor_Bulk_transport ( ) returns with a USB_STOR_TRANPORT_ERROR, usb_stor_invoke_transport ( ) tries to reset the device but fails on the reset.

4. Any subsequent CBW and CSW pair will be skewed. The CBW will receive the CSW of a previous CBW. At this point it is not recoverable except a reboot.

Example traffic:

	CBW 0
	CSW 0

	Disconnect
	Reconnect

	CBW 1
	CSW 0

	CBW 2
	CSW 1

	...

I think you get the picture. Any ideas.

- Allison B

_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel

Signature · 6 lines
Matthew Dharm                              Home: [email protected] 
Maintainer, Linux USB Mass Storage Driver

I say, what are all those naked people doing?
					-- Big client to Stef
User Friendly, 12/14/1997