summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-05-14 23:06:16 +0200
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-05-14 23:06:16 +0200
commit63b1623ef0e33160d782fd1b0044e9a8af5d16cf (patch)
tree064bde66cbf8c2ea9a1df6f23c6db0e3ad6f402a /drivers
parentalim15x3: remove stale warning about ATI RS100 northbridge (diff)
downloadlinux-63b1623ef0e33160d782fd1b0044e9a8af5d16cf.tar.xz
linux-63b1623ef0e33160d782fd1b0044e9a8af5d16cf.zip
alim15x3: add "wdc_udma" module parameter
Add "wdc_udma" module parameter for allowing UDMA transfers on M1543C-E chipset for WDC disks. Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/ide/pci/alim15x3.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/ide/pci/alim15x3.c b/drivers/ide/pci/alim15x3.c
index 98ecf1451fc7..3eaab542c41a 100644
--- a/drivers/ide/pci/alim15x3.c
+++ b/drivers/ide/pci/alim15x3.c
@@ -39,6 +39,16 @@
#include <asm/io.h>
/*
+ * Allow UDMA on M1543C-E chipset for WDC disks that ignore CRC checking
+ * (this is DANGEROUS and could result in data corruption).
+ */
+static int wdc_udma;
+
+module_param(wdc_udma, bool, 0);
+MODULE_PARM_DESC(wdc_udma,
+ "allow UDMA on M1543C-E chipset for WDC disks (DANGEROUS)");
+
+/*
* ALi devices are not plug in. Otherwise these static values would
* need to go. They ought to go away anyway
*/
@@ -116,7 +126,7 @@ static void ali_set_pio_mode(ide_drive_t *drive, const u8 pio)
* The actual rules for the ALi are:
* No UDMA on revisions <= 0x20
* Disk only for revisions < 0xC2
- * Not WDC drives for revisions < 0xC2
+ * Not WDC drives on M1543C-E (?)
*
* FIXME: WDC ifdef needs to die
*/
@@ -127,7 +137,8 @@ static u8 ali_udma_filter(ide_drive_t *drive)
if (drive->media != ide_disk)
return 0;
#ifndef CONFIG_WDC_ALI15X3
- if (chip_is_1543c_e && strstr(drive->id->model, "WDC "))
+ if (chip_is_1543c_e && strstr(drive->id->model, "WDC ") &&
+ wdc_udma == 0)
return 0;
#endif
}