Koozali.org: home of the SME Server

USB hard drive problem

Rick Jones

USB hard drive problem
« on: September 25, 2003, 02:51:18 AM »
I can't get a USB-2 hard drive to be recognised properly, and looking for ideas as to why.

The machine has 2 USB controllers in it, 1.1 on the MB plus a 2.0 PCI card. Both work fine with a USB-2 "keyring" flash-memory stick.

I also have a USB-2 adapter for an IDE drive, and this works fine on Windows XP with an 8GB FAT drive. However, plugged into e-smith it doesn't, and this is logged:

Sep 24 20:52:18 smithy kernel: SCSI device (ioctl) reports ILLEGAL REQUEST.
Sep 24 20:52:18 smithy kernel: SCSI device sda: 16498944 512-byte hdwr sectors (8447 MB)
Sep 24 20:52:18 smithy kernel: usb-uhci.c: interrupt, status 2, frame# 538
Sep 24 20:52:18 smithy kernel: sda: test WP failed, assume Write Enabled
Sep 24 20:52:18 smithy kernel:  sda: I/O error: dev 08:00, sector 0
Sep 24 20:52:18 smithy kernel:  I/O error: dev 08:00, sector 0
Sep 24 20:52:18 smithy kernel:  unable to read partition table

It's the same on both USB controllers, and I've tried a different, smaller drive on the adapter, and it still behaves the same.

The USB adapter is unbranded, but reports as EagleTec. It claims to support the relevant standards. Windows is happy with it, so why not e-smith, especially as it does work with flash "drives" ?

Any ideas?

Rick Jones

Rick Jones

Re: USB hard drive problem
« Reply #1 on: September 27, 2003, 02:56:34 AM »
Solution found! (in case anyone's interested :-/ )

A scour of the Web turned up the same problem on a LaCie drive, which uses the same EagleTec controller chip. It seems that the EagleTec is singled out for special treatment by usb-storage.o, via an entry in unusual_dev.h (kernel source). This is unnecessary, as the EagleTec's behaviour is completely standard and needs no exceptional treatment.

The true solution is to remove the entry in unusual_dev.h and re-build usb-stoarage.o, but as I don't yet understand the linux kernel make system well enough to re-compile a single driver module I patched usb-storage.o directly (change e3 05 02 07 to something else). Consequently the device is recognised and works prefectly!

Rick Jones