aboutsummaryrefslogtreecommitdiff
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)
if (mate->present == 0)
goto out;
- if ((mate->driveid->capability & 1) && __ide_dma_bad_drive(mate) == 0) {
+ if (ata_id_has_dma(mateid) && __ide_dma_bad_drive(mate) == 0) {
if ((mateid[ATA_ID_FIELD_VALID] & 4) &&
(mateid[ATA_ID_UDMA_MODES] & 7))
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)
/* In raid mode the ident block is slightly buggy
We need to set the bits so that the IDE layer knows
LBA28. LBA48 and DMA ar valid */
- drive->driveid->capability |= 3; /* LBA28, DMA */
+ id[ATA_ID_CAPABILITY] |= (3 << 8); /* LBA28, DMA */
id[ATA_ID_COMMAND_SET_2] |= 0x0400; /* LBA48 valid */
id[ATA_ID_CFS_ENABLE_2] |= 0x0400; /* LBA48 on */
/* Reporting logic */
@@ -504,7 +504,7 @@ static void it821x_quirkproc(ide_drive_t *drive)
* IDE core that DMA is supported (it821x hardware
* takes care of DMA mode programming).
*/
- if (drive->driveid->capability & 1) {
+ if (ata_id_has_dma(id)) {
id[ATA_ID_MWDMA_MODES] |= 0x0101;
drive->current_speed = XFER_MW_DMA_0;
}
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)
* Prefetch_EN / IORDY_EN / PA[3:0] bits of register A
*/
AP &= ~0x3f;
- if (drive->driveid->capability & 4)
+ if (ata_id_iordy_disable(drive->id))
AP |= 0x20; /* set IORDY_EN bit */
if (drive->media == ide_disk)
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)
if (mate->present == 0)
goto out;
- if ((mate->driveid->capability & 1) && __ide_dma_bad_drive(mate) == 0) {
+ if (ata_id_has_dma(mateid) && __ide_dma_bad_drive(mate) == 0) {
if ((mateid[ATA_ID_FIELD_VALID] & 4) &&
(mateid[ATA_ID_UDMA_MODES] & 7))
goto out;