2004年7月11日日曜日

NBJ EX35-01 USB2.0 HARD DISK DRIVE


先日、250GBのIDE-HDDHGST Deskstar 7K250を購入した。

外付けの箱1つに対して、以前から持っているドライブも含めて4台で

付け替えが発生しちょっと不便であった。



ドスパラで安い箱があるというのを見かけたので、行ってみた。

秋葉原ジャンク買い物日記に書いてあるものと同じである。

��ちょっと中身が代わっていたけど。



サクッとHDDを組み込んでみると一応認識しているようである。



しかし大量のread/writeでハングアップしてしまう。

��外付け箱のアクセスランプがつきっぱなしで、

��Linux boxからもtime outに...



「なんじゃこりゃ、腐ってる。叩き返そう!」

と思ったが、ちょっと探すと、こういうページがあった。

Re: [Linux-usb-users] Genesys Logic and Kernel 2.4


この↓パッチ当ててみて、試してみよっと。





--- 2.4.27/drivers/usb/storage/transport.c Fri Jul 9 10:56:27 2004
+++ 2.4.27-gl/drivers/usb/storage/transport.c Fri Jul 9 11:51:14 2004
@@ -1170,6 +1170,12 @@
/* if the command transfered well, then we go to the data stage */
if (result == 0) {
+
+ /* Genesys Logic interface chips need a 100us delay between
+ * the command phase and the data phase */
+ if (us->pusb_dev->descriptor.idVendor == USB_VENDOR_ID_GENESYS)
+ udelay(100);
+
/* send/receive data payload, if there is any */
if (bcb->DataTransferLength) {
usb_stor_transfer(srb, us);
--- 2.4.27/drivers/usb/storage/usb.c Fri Jul 9 11:44:53 2004
+++ 2.4.27-gl/drivers/usb/storage/usb.c Fri Jul 9 11:49:44 2004
@@ -996,6 +996,15 @@
*/
(struct us_data *)ss->htmplt.proc_dir = ss;
+ /* According to the technical support people at Genesys Logic,
+ * devices using their chips have problems transferring more
+ * than 32 KB at a time. In practice people have found that
+ * 64 KB works okay and that's what Windows does. But we'll
+ * be conservative.
+ */
+ if (ss->pusb_dev->descriptor.idVendor == USB_VENDOR_ID_GENESYS)
+ ss->htmplt->max_sectors = 64;
+
/* Just before we start our control thread, initialize
* the device if it needs initialization */
if (unusual_dev && unusual_dev->initFunction)
--- 2.4.27/drivers/usb/storage/usb.h Fri Jul 9 10:56:03 2004
+++ 2.4.27-gl/drivers/usb/storage/usb.h Fri Jul 9 11:45:49 2004
@@ -193,4 +193,7 @@
/* Function to fill an inquiry response. See usb.c for details */
extern void fill_inquiry_response(struct us_data *us,
unsigned char *data, unsigned int data_len);
+
+/* Vendor ID list for devices that require special handling */
+#define USB_VENDOR_ID_GENESYS 0x05e3 /* Genesys Logic */
#endif



��Windowsだと、ちゃんと動くんだろうか?

��WindowsXP/2000だと、標準device driverのはずなんだけど。

��アクセスが遅いから、大丈夫だとか言うことはないよな?(^^;>Windows



追記。

上記パッチ、タイプミスがあるようだな。

誤:ss->htmplt->max_sectors = 64;

正:ss->htmplt.max_sectors = 64;

これで動くかなぁ。


3 件のコメント:

  1. さらに追記。
    今のところ、数十GBのファイルを外付け箱のHDDに書きだしているけど、順調に動いているな。

    返信削除
  2. さらに動作状況追記。
    数十GBのファイルの読み書きでもいい感じ。
    但し、cp -auvでの箱からの読み出しで、
    2回(2つのfaileで) i/o errorが出ているようだ。
    rsyncでの読み出しで再度やると、エラーになったfileも
    きちんと読み出せた模様。

    返信削除
  3. 先日NBJ EX35-01とシーゲイト160G合わせて購入。 組み立てても認識せず・・・ジャンパーをマスターにしたら認識しました。以上ご報告でした。

    返信削除