aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/pci/sis5513.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/pci/sis5513.c')
-rw-r--r--drivers/ide/pci/sis5513.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/drivers/ide/pci/sis5513.c b/drivers/ide/pci/sis5513.c
index 3a8cb1468a76..3e18899de631 100644
--- a/drivers/ide/pci/sis5513.c
+++ b/drivers/ide/pci/sis5513.c
@@ -519,15 +519,10 @@ static void config_art_rwp_pio (ide_drive_t *drive, u8 pio)
519 } 519 }
520} 520}
521 521
522static int sis5513_tune_drive(ide_drive_t *drive, const u8 pio)
523{
524 config_art_rwp_pio(drive, pio);
525 return ide_config_drive_speed(drive, XFER_PIO_0 + pio);
526}
527
528static void sis_set_pio_mode(ide_drive_t *drive, const u8 pio) 522static void sis_set_pio_mode(ide_drive_t *drive, const u8 pio)
529{ 523{
530 (void)sis5513_tune_drive(drive, pio); 524 config_art_rwp_pio(drive, pio);
525 (void)ide_config_drive_speed(drive, XFER_PIO_0 + pio);
531} 526}
532 527
533static int sis5513_tune_chipset(ide_drive_t *drive, const u8 speed) 528static int sis5513_tune_chipset(ide_drive_t *drive, const u8 speed)
@@ -537,9 +532,6 @@ static int sis5513_tune_chipset(ide_drive_t *drive, const u8 speed)
537 u32 regdw; 532 u32 regdw;
538 u8 drive_pci, reg; 533 u8 drive_pci, reg;
539 534
540 if (speed >= XFER_PIO_0 && speed <= XFER_PIO_4)
541 return sis5513_tune_drive(drive, speed - XFER_PIO_0);
542
543 /* See config_art_rwp_pio for drive pci config registers */ 535 /* See config_art_rwp_pio for drive pci config registers */
544 drive_pci = 0x40; 536 drive_pci = 0x40;
545 if (chipset_family >= ATA_133) { 537 if (chipset_family >= ATA_133) {