From 943547abdfe9b4e27e36a25987909619908dffbf Mon Sep 17 00:00:00 2001 From: Bartlomiej Zolnierkiewicz Date: Sun, 2 Dec 2007 03:47:01 +0100 Subject: pata_amd/pata_via: de-couple programming of PIO/MWDMA and UDMA timings * Don't program UDMA timings when programming PIO or MWDMA modes. This has also a nice side-effect of fixing regression added by commit 681c80b5d96076f447e8101ac4325c82d8dce508 ("libata: correct handling of SRST reset sequences") (->set_piomode method for PIO0 is called before ->cable_detect method which checks UDMA timings to get the cable type). * Bump driver version. Signed-off-by: Bartlomiej Zolnierkiewicz Tested-by: "Thomas Lindroth" Acked-by: Alan Cox Cc: Tejun Heo Signed-off-by: Andrew Morton Signed-off-by: Bartlomiej Zolnierkiewicz Signed-off-by: Jeff Garzik --- drivers/ata/pata_amd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'drivers/ata/pata_amd.c') diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c index c5779ad4abc..3cc27b51465 100644 --- a/drivers/ata/pata_amd.c +++ b/drivers/ata/pata_amd.c @@ -25,7 +25,7 @@ #include #define DRV_NAME "pata_amd" -#define DRV_VERSION "0.3.9" +#define DRV_VERSION "0.3.10" /** * timing_setup - shared timing computation and load @@ -115,7 +115,8 @@ static void timing_setup(struct ata_port *ap, struct ata_device *adev, int offse } /* UDMA timing */ - pci_write_config_byte(pdev, offset + 0x10 + (3 - dn), t); + if (at.udma) + pci_write_config_byte(pdev, offset + 0x10 + (3 - dn), t); } /** -- cgit v1.2.3