Re: 2.6.5-rc3: cat /proc/ide/hpt366 kills disk on second channel

From: Bartlomiej Zolnierkiewicz
Date: Tue Apr 06 2004 - 11:53:41 EST



Can you try this patch?

It seems somebody tried to do write access
from /proc handler without _any_ locking.

Regards,
Bartlomiej

--- linux-2.6.5/drivers/ide/pci/hpt366.c 2004-04-05 21:53:45.000000000 +0200
+++ linux/drivers/ide/pci/hpt366.c 2004-04-06 18:54:24.756073752 +0200
@@ -107,7 +107,7 @@
" %s\n",
(c0 & 0x80) ? "no" : "yes",
(c1 & 0x80) ? "no" : "yes");
-
+#if 0
if (hpt_minimum_revision(dev, 3)) {
u8 cbl;
cbl = inb(iobase + 0x7b);
@@ -120,7 +120,7 @@
(cbl & 0x01) ? 33 : 66);
p += sprintf(p, "\n");
}
-
+#endif
p += sprintf(p, "--------------- drive0 --------- drive1 "
"------- drive0 ---------- drive1 -------\n");
p += sprintf(p, "DMA capable: %s %s"

-
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/