aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/pci
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/pci')
-rw-r--r--drivers/ide/pci/cs5530.c2
-rw-r--r--drivers/ide/pci/it821x.c4
-rw-r--r--drivers/ide/pci/pdc202xx_old.c2
-rw-r--r--drivers/ide/pci/sc1200.c2
4 files changed, 5 insertions, 5 deletions
diff --git a/drivers/ide/pci/cs5530.c b/drivers/ide/pci/cs5530.c
index 774ff58603a..ef91e9d7c54 100644
--- a/drivers/ide/pci/cs5530.c
+++ b/drivers/ide/pci/cs5530.c
@@ -88,7 +88,7 @@ static u8 cs5530_udma_filter(ide_drive_t *drive)
88 if (mate->present == 0) 88 if (mate->present == 0)
89 goto out; 89 goto out;
90 90
91 if ((mate->driveid->capability & 1) && __ide_dma_bad_drive(mate) == 0) { 91 if (ata_id_has_dma(mateid) && __ide_dma_bad_drive(mate) == 0) {
92 if ((mateid[ATA_ID_FIELD_VALID] & 4) && 92 if ((mateid[ATA_ID_FIELD_VALID] & 4) &&
93 (mateid[ATA_ID_UDMA_MODES] & 7)) 93 (mateid[ATA_ID_UDMA_MODES] & 7))
94 goto out; 94 goto out;
diff --git a/drivers/ide/pci/it821x.c b/drivers/ide/pci/it821x.c
index 31d4e6aef1b..ed24065f74e 100644
--- a/drivers/ide/pci/it821x.c
+++ b/drivers/ide/pci/it821x.c
@@ -470,7 +470,7 @@ static void it821x_quirkproc(ide_drive_t *drive)
470 /* In raid mode the ident block is slightly buggy 470 /* In raid mode the ident block is slightly buggy
471 We need to set the bits so that the IDE layer knows 471 We need to set the bits so that the IDE layer knows
472 LBA28. LBA48 and DMA ar valid */ 472 LBA28. LBA48 and DMA ar valid */
473 drive->driveid->capability |= 3; /* LBA28, DMA */ 473 id[ATA_ID_CAPABILITY] |= (3 << 8); /* LBA28, DMA */
474 id[ATA_ID_COMMAND_SET_2] |= 0x0400; /* LBA48 valid */ 474 id[ATA_ID_COMMAND_SET_2] |= 0x0400; /* LBA48 valid */
475 id[ATA_ID_CFS_ENABLE_2] |= 0x0400; /* LBA48 on */ 475 id[ATA_ID_CFS_ENABLE_2] |= 0x0400; /* LBA48 on */
476 /* Reporting logic */ 476 /* Reporting logic */
@@ -504,7 +504,7 @@ static void it821x_quirkproc(ide_drive_t *drive)
504 * IDE core that DMA is supported (it821x hardware 504 * IDE core that DMA is supported (it821x hardware
505 * takes care of DMA mode programming). 505 * takes care of DMA mode programming).
506 */ 506 */
507 if (drive->driveid->capability & 1) { 507 if (ata_id_has_dma(id)) {
508 id[ATA_ID_MWDMA_MODES] |= 0x0101; 508 id[ATA_ID_MWDMA_MODES] |= 0x0101;
509 drive->current_speed = XFER_MW_DMA_0; 509 drive->current_speed = XFER_MW_DMA_0;
510 } 510 }
diff --git a/drivers/ide/pci/pdc202xx_old.c b/drivers/ide/pci/pdc202xx_old.c
index 23e861b177c..5d4436f3efd 100644
--- a/drivers/ide/pci/pdc202xx_old.c
+++ b/drivers/ide/pci/pdc202xx_old.c
@@ -86,7 +86,7 @@ static void pdc202xx_set_mode(ide_drive_t *drive, const u8 speed)
86 * Prefetch_EN / IORDY_EN / PA[3:0] bits of register A 86 * Prefetch_EN / IORDY_EN / PA[3:0] bits of register A
87 */ 87 */
88 AP &= ~0x3f; 88 AP &= ~0x3f;
89 if (drive->driveid->capability & 4) 89 if (ata_id_iordy_disable(drive->id))
90 AP |= 0x20; /* set IORDY_EN bit */ 90 AP |= 0x20; /* set IORDY_EN bit */
91 if (drive->media == ide_disk) 91 if (drive->media == ide_disk)
92 AP |= 0x10; /* set Prefetch_EN bit */ 92 AP |= 0x10; /* set Prefetch_EN bit */
diff --git a/drivers/ide/pci/sc1200.c b/drivers/ide/pci/sc1200.c
index 5c8367df14e..695cc974204 100644
--- a/drivers/ide/pci/sc1200.c
+++ b/drivers/ide/pci/sc1200.c
@@ -111,7 +111,7 @@ static u8 sc1200_udma_filter(ide_drive_t *drive)
111 if (mate->present == 0) 111 if (mate->present == 0)
112 goto out; 112 goto out;
113 113
114 if ((mate->driveid->capability & 1) && __ide_dma_bad_drive(mate) == 0) { 114 if (ata_id_has_dma(mateid) && __ide_dma_bad_drive(mate) == 0) {
115 if ((mateid[ATA_ID_FIELD_VALID] & 4) && 115 if ((mateid[ATA_ID_FIELD_VALID] & 4) &&
116 (mateid[ATA_ID_UDMA_MODES] & 7)) 116 (mateid[ATA_ID_UDMA_MODES] & 7))
117 goto out; 117 goto out;