patch-2.4.19 linux-2.4.19/drivers/ide/slc90e66.c
Next file: linux-2.4.19/drivers/ide/via82cxxx.c
Previous file: linux-2.4.19/drivers/ide/sis5513.c
Back to the patch index
Back to the overall index
- Lines: 38
- Date:
Fri Aug 2 17:39:44 2002
- Orig file:
linux-2.4.18/drivers/ide/slc90e66.c
- Orig date:
Sun Jul 15 16:22:23 2001
diff -urN linux-2.4.18/drivers/ide/slc90e66.c linux-2.4.19/drivers/ide/slc90e66.c
@@ -86,8 +86,13 @@
* at that point bibma+0x2 et bibma+0xa are byte registers
* to investigate:
*/
+#ifdef __mips__ /* only for mips? */
+ c0 = inb_p(bibma + 0x02);
+ c1 = inb_p(bibma + 0x0a);
+#else
c0 = inb_p((unsigned short)bibma + 0x02);
c1 = inb_p((unsigned short)bibma + 0x0a);
+#endif
p += sprintf(p, " SLC90E66 Chipset.\n");
p += sprintf(p, "--------------- Primary Channel ---------------- Secondary Channel -------------\n");
@@ -253,7 +258,9 @@
case XFER_MW_DMA_2:
case XFER_MW_DMA_1:
case XFER_SW_DMA_2: break;
+#if 0 /* allow PIO modes */
default: return -1;
+#endif
}
if (speed >= XFER_UDMA_0) {
@@ -291,6 +298,13 @@
byte speed = 0;
byte udma_66 = eighty_ninty_three(drive);
+#if 1 /* allow PIO modes */
+ if (!HWIF(drive)->autodma) {
+ speed = XFER_PIO_0 + ide_get_best_pio_mode(drive, 255, 5, NULL);
+ (void) slc90e66_tune_chipset(drive, speed);
+ return ((int) ide_dma_off_quietly);
+ }
+#endif
if ((id->dma_ultra & 0x0010) && (ultra)) {
speed = (udma_66) ? XFER_UDMA_4 : XFER_UDMA_2;
} else if ((id->dma_ultra & 0x0008) && (ultra)) {
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)