aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-05-24 11:05:29 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-24 11:05:29 -0400
commit7e125f7b9cbfce4101191b8076d606c517a73066 (patch)
treeded140947b146cc7177519cd23cf81912de32687 /drivers/ide
parent064e297c324fff9b62226aae5dc468ebb272433c (diff)
parenta9ddabc52ce3757a4331d6c1e8bf4065333cc51b (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide-2.6: cmd640: fix kernel oops in test_irq() method pdc202xx_old: ignore "FIFO empty" bit in test_irq() method pdc202xx_old: wire test_irq() method for PDC2026x IDE: pass IRQ flags to the IDE core ide: fix comment typo in ide.h
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/cmd640.c6
-rw-r--r--drivers/ide/ide_platform.c1
-rw-r--r--drivers/ide/pdc202xx_old.c5
3 files changed, 6 insertions, 6 deletions
diff --git a/drivers/ide/cmd640.c b/drivers/ide/cmd640.c
index d2b8b272bc27..cb10201a15ed 100644
--- a/drivers/ide/cmd640.c
+++ b/drivers/ide/cmd640.c
@@ -633,12 +633,10 @@ static void __init cmd640_init_dev(ide_drive_t *drive)
633 633
634static int cmd640_test_irq(ide_hwif_t *hwif) 634static int cmd640_test_irq(ide_hwif_t *hwif)
635{ 635{
636 struct pci_dev *dev = to_pci_dev(hwif->dev);
637 int irq_reg = hwif->channel ? ARTTIM23 : CFR; 636 int irq_reg = hwif->channel ? ARTTIM23 : CFR;
638 u8 irq_stat, irq_mask = hwif->channel ? ARTTIM23_IDE23INTR : 637 u8 irq_mask = hwif->channel ? ARTTIM23_IDE23INTR :
639 CFR_IDE01INTR; 638 CFR_IDE01INTR;
640 639 u8 irq_stat = get_cmd640_reg(irq_reg);
641 pci_read_config_byte(dev, irq_reg, &irq_stat);
642 640
643 return (irq_stat & irq_mask) ? 1 : 0; 641 return (irq_stat & irq_mask) ? 1 : 0;
644} 642}
diff --git a/drivers/ide/ide_platform.c b/drivers/ide/ide_platform.c
index 42965b3e30b9..542603b394e4 100644
--- a/drivers/ide/ide_platform.c
+++ b/drivers/ide/ide_platform.c
@@ -95,6 +95,7 @@ static int __devinit plat_ide_probe(struct platform_device *pdev)
95 plat_ide_setup_ports(&hw, base, alt_base, pdata, res_irq->start); 95 plat_ide_setup_ports(&hw, base, alt_base, pdata, res_irq->start);
96 hw.dev = &pdev->dev; 96 hw.dev = &pdev->dev;
97 97
98 d.irq_flags = res_irq->flags;
98 if (mmio) 99 if (mmio)
99 d.host_flags |= IDE_HFLAG_MMIO; 100 d.host_flags |= IDE_HFLAG_MMIO;
100 101
diff --git a/drivers/ide/pdc202xx_old.c b/drivers/ide/pdc202xx_old.c
index c5f3841af360..3a35ec6193d2 100644
--- a/drivers/ide/pdc202xx_old.c
+++ b/drivers/ide/pdc202xx_old.c
@@ -93,13 +93,13 @@ static int pdc202xx_test_irq(ide_hwif_t *hwif)
93 * bit 7: error, bit 6: interrupting, 93 * bit 7: error, bit 6: interrupting,
94 * bit 5: FIFO full, bit 4: FIFO empty 94 * bit 5: FIFO full, bit 4: FIFO empty
95 */ 95 */
96 return ((sc1d & 0x50) == 0x50) ? 1 : 0; 96 return (sc1d & 0x40) ? 1 : 0;
97 } else { 97 } else {
98 /* 98 /*
99 * bit 3: error, bit 2: interrupting, 99 * bit 3: error, bit 2: interrupting,
100 * bit 1: FIFO full, bit 0: FIFO empty 100 * bit 1: FIFO full, bit 0: FIFO empty
101 */ 101 */
102 return ((sc1d & 0x05) == 0x05) ? 1 : 0; 102 return (sc1d & 0x04) ? 1 : 0;
103 } 103 }
104} 104}
105 105
@@ -241,6 +241,7 @@ static const struct ide_port_ops pdc20246_port_ops = {
241static const struct ide_port_ops pdc2026x_port_ops = { 241static const struct ide_port_ops pdc2026x_port_ops = {
242 .set_pio_mode = pdc202xx_set_pio_mode, 242 .set_pio_mode = pdc202xx_set_pio_mode,
243 .set_dma_mode = pdc202xx_set_mode, 243 .set_dma_mode = pdc202xx_set_mode,
244 .test_irq = pdc202xx_test_irq,
244 .cable_detect = pdc2026x_cable_detect, 245 .cable_detect = pdc2026x_cable_detect,
245}; 246};
246 247