diff options
Diffstat (limited to 'drivers/ide/pci/pdc202xx_new.c')
-rw-r--r-- | drivers/ide/pci/pdc202xx_new.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/ide/pci/pdc202xx_new.c b/drivers/ide/pci/pdc202xx_new.c index bb29db03540e..1c8cb7797a4a 100644 --- a/drivers/ide/pci/pdc202xx_new.c +++ b/drivers/ide/pci/pdc202xx_new.c | |||
@@ -19,18 +19,12 @@ | |||
19 | #include <linux/types.h> | 19 | #include <linux/types.h> |
20 | #include <linux/kernel.h> | 20 | #include <linux/kernel.h> |
21 | #include <linux/delay.h> | 21 | #include <linux/delay.h> |
22 | #include <linux/timer.h> | ||
23 | #include <linux/mm.h> | ||
24 | #include <linux/ioport.h> | ||
25 | #include <linux/blkdev.h> | ||
26 | #include <linux/hdreg.h> | 22 | #include <linux/hdreg.h> |
27 | #include <linux/interrupt.h> | ||
28 | #include <linux/pci.h> | 23 | #include <linux/pci.h> |
29 | #include <linux/init.h> | 24 | #include <linux/init.h> |
30 | #include <linux/ide.h> | 25 | #include <linux/ide.h> |
31 | 26 | ||
32 | #include <asm/io.h> | 27 | #include <asm/io.h> |
33 | #include <asm/irq.h> | ||
34 | 28 | ||
35 | #ifdef CONFIG_PPC_PMAC | 29 | #ifdef CONFIG_PPC_PMAC |
36 | #include <asm/prom.h> | 30 | #include <asm/prom.h> |
@@ -197,7 +191,7 @@ static void pdcnew_set_pio_mode(ide_drive_t *drive, const u8 pio) | |||
197 | } | 191 | } |
198 | } | 192 | } |
199 | 193 | ||
200 | static u8 pdcnew_cable_detect(ide_hwif_t *hwif) | 194 | static u8 __devinit pdcnew_cable_detect(ide_hwif_t *hwif) |
201 | { | 195 | { |
202 | if (get_indexed_reg(hwif, 0x0b) & 0x04) | 196 | if (get_indexed_reg(hwif, 0x0b) & 0x04) |
203 | return ATA_CBL_PATA40; | 197 | return ATA_CBL_PATA40; |
@@ -456,11 +450,7 @@ static void __devinit init_hwif_pdc202new(ide_hwif_t *hwif) | |||
456 | hwif->quirkproc = &pdcnew_quirkproc; | 450 | hwif->quirkproc = &pdcnew_quirkproc; |
457 | hwif->resetproc = &pdcnew_reset; | 451 | hwif->resetproc = &pdcnew_reset; |
458 | 452 | ||
459 | if (hwif->dma_base == 0) | 453 | hwif->cable_detect = pdcnew_cable_detect; |
460 | return; | ||
461 | |||
462 | if (hwif->cbl != ATA_CBL_PATA40_SHORT) | ||
463 | hwif->cbl = pdcnew_cable_detect(hwif); | ||
464 | } | 454 | } |
465 | 455 | ||
466 | static struct pci_dev * __devinit pdc20270_get_dev2(struct pci_dev *dev) | 456 | static struct pci_dev * __devinit pdc20270_get_dev2(struct pci_dev *dev) |