Help with USB storage program and USB 3.0
OK, I admit I'm a newbie at this - especially the linux part. I have inherited a USB storage program that tests USB hard disk drives. Up to now, I have been successful at making updates to the code when needed because accessing the USB device has never been a problem.
First, I am running Slackware 12.1.0 with Linux Kernel 22.214.171.124.
The program basically monitors the USB devices via /proc/bus/usb/devices and when there's a new device, checks to see if the vendor ID is one it should test. If so, the first thing it does is go out and do a read capacity via the usb_bulk_write (eventually), which I assume is in the usb library located in /usr/include (please verify). I know that usb.h is in the includes in the usb_storage.c that is part of the program code.
Anyway, this has always worked on USB 2.0 devices, but now that I have a USB 3.0 device, it errors out at the usb_bulk_write command (return code is 31). I was under the impression that USB 3.0 was backward compatible. Also, if I just plug in the drive without running my program, the system sees it just fine. I am just plugging the USB 3.0 device into a USB 2.0 bus.
I am kind of at a loss as to what would be causing this. Seems to me if it worked on USB 2.0, it would work on 3.0. Any ideas would be appreciated.
Last edited by Equinn; 01-25-2011 at 02:39 PM.