diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-10-18 18:30:07 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-10-18 18:30:07 -0400 |
commit | 5f8b6c34854a966fe5eb7241fde0419d47d5d408 (patch) | |
tree | 052afd508d9cd314f503d938182db55355f1b392 /drivers/ide/pci/hpt366.c | |
parent | 9adf768a398745c539623210502b521e671c59d7 (diff) |
ide: add ->mwdma_mask and ->swdma_mask to ide_pci_device_t (take 2)
* Add ->mwdma_mask and ->swdma_mask to ide_pci_device_t.
* Set ide_hwif_t DMA masks using DMA masks from ide_pci_device_t in
setup-pci.c::ide_pci_setup_ports() (iff DMA base is valid and ->init_hwif
method may still override them).
* Convert IDE PCI host drivers to use ide_pci_device_t DMA masks.
While at it:
* Use ATA_{UDMA,MWDMA,SWDMA}* defines.
* hpt34x.c: add separate ide_pci_device_t instances for HPT343 and HPT345.
* serverworks.c: fix DMA masks being set before checking DMA base.
v2:
* Add missing masks to DECLARE_GENERIC_PCI_DEV() macro.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/pci/hpt366.c')
-rw-r--r-- | drivers/ide/pci/hpt366.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/ide/pci/hpt366.c b/drivers/ide/pci/hpt366.c index a805236bbae6..e643b9654c75 100644 --- a/drivers/ide/pci/hpt366.c +++ b/drivers/ide/pci/hpt366.c | |||
@@ -1296,9 +1296,6 @@ static void __devinit init_hwif_hpt366(ide_hwif_t *hwif) | |||
1296 | if (hwif->dma_base == 0) | 1296 | if (hwif->dma_base == 0) |
1297 | return; | 1297 | return; |
1298 | 1298 | ||
1299 | hwif->ultra_mask = hwif->cds->udma_mask; | ||
1300 | hwif->mwdma_mask = 0x07; | ||
1301 | |||
1302 | /* | 1299 | /* |
1303 | * The HPT37x uses the CBLID pins as outputs for MA15/MA16 | 1300 | * The HPT37x uses the CBLID pins as outputs for MA15/MA16 |
1304 | * address lines to access an external EEPROM. To read valid | 1301 | * address lines to access an external EEPROM. To read valid |
@@ -1555,6 +1552,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1555 | .extra = 240, | 1552 | .extra = 240, |
1556 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1553 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1557 | .pio_mask = ATA_PIO4, | 1554 | .pio_mask = ATA_PIO4, |
1555 | .mwdma_mask = ATA_MWDMA2, | ||
1558 | },{ /* 1 */ | 1556 | },{ /* 1 */ |
1559 | .name = "HPT372A", | 1557 | .name = "HPT372A", |
1560 | .init_setup = init_setup_hpt372a, | 1558 | .init_setup = init_setup_hpt372a, |
@@ -1566,6 +1564,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1566 | .extra = 240, | 1564 | .extra = 240, |
1567 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1565 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1568 | .pio_mask = ATA_PIO4, | 1566 | .pio_mask = ATA_PIO4, |
1567 | .mwdma_mask = ATA_MWDMA2, | ||
1569 | },{ /* 2 */ | 1568 | },{ /* 2 */ |
1570 | .name = "HPT302", | 1569 | .name = "HPT302", |
1571 | .init_setup = init_setup_hpt302, | 1570 | .init_setup = init_setup_hpt302, |
@@ -1577,6 +1576,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1577 | .extra = 240, | 1576 | .extra = 240, |
1578 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1577 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1579 | .pio_mask = ATA_PIO4, | 1578 | .pio_mask = ATA_PIO4, |
1579 | .mwdma_mask = ATA_MWDMA2, | ||
1580 | },{ /* 3 */ | 1580 | },{ /* 3 */ |
1581 | .name = "HPT371", | 1581 | .name = "HPT371", |
1582 | .init_setup = init_setup_hpt371, | 1582 | .init_setup = init_setup_hpt371, |
@@ -1588,6 +1588,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1588 | .extra = 240, | 1588 | .extra = 240, |
1589 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1589 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1590 | .pio_mask = ATA_PIO4, | 1590 | .pio_mask = ATA_PIO4, |
1591 | .mwdma_mask = ATA_MWDMA2, | ||
1591 | },{ /* 4 */ | 1592 | },{ /* 4 */ |
1592 | .name = "HPT374", | 1593 | .name = "HPT374", |
1593 | .init_setup = init_setup_hpt374, | 1594 | .init_setup = init_setup_hpt374, |
@@ -1599,6 +1600,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1599 | .extra = 240, | 1600 | .extra = 240, |
1600 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1601 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1601 | .pio_mask = ATA_PIO4, | 1602 | .pio_mask = ATA_PIO4, |
1603 | .mwdma_mask = ATA_MWDMA2, | ||
1602 | },{ /* 5 */ | 1604 | },{ /* 5 */ |
1603 | .name = "HPT372N", | 1605 | .name = "HPT372N", |
1604 | .init_setup = init_setup_hpt372n, | 1606 | .init_setup = init_setup_hpt372n, |
@@ -1610,6 +1612,7 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1610 | .extra = 240, | 1612 | .extra = 240, |
1611 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, | 1613 | .host_flags = IDE_HFLAG_NO_ATAPI_DMA | IDE_HFLAG_OFF_BOARD, |
1612 | .pio_mask = ATA_PIO4, | 1614 | .pio_mask = ATA_PIO4, |
1615 | .mwdma_mask = ATA_MWDMA2, | ||
1613 | } | 1616 | } |
1614 | }; | 1617 | }; |
1615 | 1618 | ||