diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-07-19 19:11:55 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2007-07-19 19:11:55 -0400 |
commit | a5d8c5c834d3cabf4b7b477c3f6ee923c25026fc (patch) | |
tree | 19fc04470569a3c2f227d5aac3078a15ac65bb32 /drivers/ide/pci/hpt366.c | |
parent | 2229833c1365346b64357a9263fa724f74f5e376 (diff) |
ide: add ide_pci_device_t.host_flags (take 2)
* Rename ide_pci_device_t.flags to ide_pci_device_t.host_flags
and IDEPCI_FLAG_ISA_PORTS flag to IDE_HFLAG_ISA_PORTS.
* Add IDE_HFLAG_SINGLE flag for single channel devices.
* Convert core code and all IDE PCI drivers to use IDE_HFLAG_SINGLE
and remove no longer needed ide_pci_device_t.channels field.
v2:
* Fix issues noticed by Sergei:
- correct code alignment in scc_pata.c
- s/IDE_HFLAG_SINGLE/~IDE_HFLAG_SINGLE/ in serverworks.c
Acked-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/pci/hpt366.c')
-rw-r--r-- | drivers/ide/pci/hpt366.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/ide/pci/hpt366.c b/drivers/ide/pci/hpt366.c index 81853d740aee..182346a04f36 100644 --- a/drivers/ide/pci/hpt366.c +++ b/drivers/ide/pci/hpt366.c | |||
@@ -1483,7 +1483,7 @@ static int __devinit init_setup_hpt366(struct pci_dev *dev, ide_pci_device_t *d) | |||
1483 | * to both functions -- really stupid design decision... :-( | 1483 | * to both functions -- really stupid design decision... :-( |
1484 | * Bit 4 is for the primary channel, bit 5 for the secondary. | 1484 | * Bit 4 is for the primary channel, bit 5 for the secondary. |
1485 | */ | 1485 | */ |
1486 | d->channels = 1; | 1486 | d->host_flags |= IDE_HFLAG_SINGLE; |
1487 | d->enablebits[0].mask = d->enablebits[0].val = 0x10; | 1487 | d->enablebits[0].mask = d->enablebits[0].val = 0x10; |
1488 | 1488 | ||
1489 | d->udma_mask = HPT366_ALLOW_ATA66_3 ? | 1489 | d->udma_mask = HPT366_ALLOW_ATA66_3 ? |
@@ -1546,7 +1546,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1546 | .init_chipset = init_chipset_hpt366, | 1546 | .init_chipset = init_chipset_hpt366, |
1547 | .init_hwif = init_hwif_hpt366, | 1547 | .init_hwif = init_hwif_hpt366, |
1548 | .init_dma = init_dma_hpt366, | 1548 | .init_dma = init_dma_hpt366, |
1549 | .channels = 2, | ||
1550 | .autodma = AUTODMA, | 1549 | .autodma = AUTODMA, |
1551 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1550 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1552 | .bootable = OFF_BOARD, | 1551 | .bootable = OFF_BOARD, |
@@ -1557,7 +1556,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1557 | .init_chipset = init_chipset_hpt366, | 1556 | .init_chipset = init_chipset_hpt366, |
1558 | .init_hwif = init_hwif_hpt366, | 1557 | .init_hwif = init_hwif_hpt366, |
1559 | .init_dma = init_dma_hpt366, | 1558 | .init_dma = init_dma_hpt366, |
1560 | .channels = 2, | ||
1561 | .autodma = AUTODMA, | 1559 | .autodma = AUTODMA, |
1562 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1560 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1563 | .udma_mask = HPT372_ALLOW_ATA133_6 ? 0x7f : 0x3f, | 1561 | .udma_mask = HPT372_ALLOW_ATA133_6 ? 0x7f : 0x3f, |
@@ -1569,7 +1567,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1569 | .init_chipset = init_chipset_hpt366, | 1567 | .init_chipset = init_chipset_hpt366, |
1570 | .init_hwif = init_hwif_hpt366, | 1568 | .init_hwif = init_hwif_hpt366, |
1571 | .init_dma = init_dma_hpt366, | 1569 | .init_dma = init_dma_hpt366, |
1572 | .channels = 2, | ||
1573 | .autodma = AUTODMA, | 1570 | .autodma = AUTODMA, |
1574 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1571 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1575 | .udma_mask = HPT302_ALLOW_ATA133_6 ? 0x7f : 0x3f, | 1572 | .udma_mask = HPT302_ALLOW_ATA133_6 ? 0x7f : 0x3f, |
@@ -1581,7 +1578,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1581 | .init_chipset = init_chipset_hpt366, | 1578 | .init_chipset = init_chipset_hpt366, |
1582 | .init_hwif = init_hwif_hpt366, | 1579 | .init_hwif = init_hwif_hpt366, |
1583 | .init_dma = init_dma_hpt366, | 1580 | .init_dma = init_dma_hpt366, |
1584 | .channels = 2, | ||
1585 | .autodma = AUTODMA, | 1581 | .autodma = AUTODMA, |
1586 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1582 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1587 | .udma_mask = HPT371_ALLOW_ATA133_6 ? 0x7f : 0x3f, | 1583 | .udma_mask = HPT371_ALLOW_ATA133_6 ? 0x7f : 0x3f, |
@@ -1593,7 +1589,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1593 | .init_chipset = init_chipset_hpt366, | 1589 | .init_chipset = init_chipset_hpt366, |
1594 | .init_hwif = init_hwif_hpt366, | 1590 | .init_hwif = init_hwif_hpt366, |
1595 | .init_dma = init_dma_hpt366, | 1591 | .init_dma = init_dma_hpt366, |
1596 | .channels = 2, /* 4 */ | ||
1597 | .autodma = AUTODMA, | 1592 | .autodma = AUTODMA, |
1598 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1593 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1599 | .udma_mask = 0x3f, | 1594 | .udma_mask = 0x3f, |
@@ -1605,7 +1600,6 @@ static ide_pci_device_t hpt366_chipsets[] __devinitdata = { | |||
1605 | .init_chipset = init_chipset_hpt366, | 1600 | .init_chipset = init_chipset_hpt366, |
1606 | .init_hwif = init_hwif_hpt366, | 1601 | .init_hwif = init_hwif_hpt366, |
1607 | .init_dma = init_dma_hpt366, | 1602 | .init_dma = init_dma_hpt366, |
1608 | .channels = 2, /* 4 */ | ||
1609 | .autodma = AUTODMA, | 1603 | .autodma = AUTODMA, |
1610 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, | 1604 | .enablebits = {{0x50,0x04,0x04}, {0x54,0x04,0x04}}, |
1611 | .udma_mask = HPT372_ALLOW_ATA133_6 ? 0x7f : 0x3f, | 1605 | .udma_mask = HPT372_ALLOW_ATA133_6 ? 0x7f : 0x3f, |