From 4e5a68aeb6b513ee0adda11642e10e528b7721c0 Mon Sep 17 00:00:00 2001 From: Sergei Shtylyov Date: Fri, 1 Feb 2008 23:09:29 +0100 Subject: trm290: cannot call ide_setup_dma() The TRM-290 chip is *not* SFF-8038i compatible and therefore can *not* call ide_setup_dma() -- fix this and also cleanup the code a bit... Signed-off-by: Sergei Shtylyov Signed-off-by: Bartlomiej Zolnierkiewicz --- drivers/ide/ide-dma.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'drivers/ide/ide-dma.c') diff --git a/drivers/ide/ide-dma.c b/drivers/ide/ide-dma.c index 15f8c6abe42..8d668a80adb 100644 --- a/drivers/ide/ide-dma.c +++ b/drivers/ide/ide-dma.c @@ -933,6 +933,8 @@ static int ide_dma_iobase(ide_hwif_t *hwif, unsigned long base, unsigned int por void ide_setup_dma(ide_hwif_t *hwif, unsigned long base, unsigned num_ports) { + u8 dma_stat; + if (ide_dma_iobase(hwif, base, num_ports)) return; @@ -971,13 +973,10 @@ void ide_setup_dma(ide_hwif_t *hwif, unsigned long base, unsigned num_ports) if (!hwif->dma_lost_irq) hwif->dma_lost_irq = &ide_dma_lost_irq; - if (hwif->chipset != ide_trm290) { - u8 dma_stat = hwif->INB(hwif->dma_status); - printk(", BIOS settings: %s:%s, %s:%s", - hwif->drives[0].name, (dma_stat & 0x20) ? "DMA" : "pio", - hwif->drives[1].name, (dma_stat & 0x40) ? "DMA" : "pio"); - } - printk("\n"); + dma_stat = hwif->INB(hwif->dma_status); + printk(KERN_CONT ", BIOS settings: %s:%s, %s:%s\n", + hwif->drives[0].name, (dma_stat & 0x20) ? "DMA" : "PIO", + hwif->drives[1].name, (dma_stat & 0x40) ? "DMA" : "PIO"); } EXPORT_SYMBOL_GPL(ide_setup_dma); -- cgit v1.2.3