aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
authorSergei Shtylyov <sshtylyov@ru.mvista.com>2007-11-13 16:09:14 -0500
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2007-11-13 16:09:14 -0500
commit6183289cd4356b790c5eaa619020fb887ec0fa44 (patch)
treed47fd4c1188134b37ee2dc83b9f85a28b5b2e756 /drivers/ide
parent9418d5dc9ba40b88737580457bf3b7c63c60ec43 (diff)
cmd64x: don't clear the other channel's interrupt
Make sure to not clear the other IDE channel's interrupt when clearing an IDE interrupt via the MRDMODE register. Thanks to Bart for finding a coding mistake. Bart: This fixes regression from commit 66602c83dcb6a5d82772d88ae7a32cd4a1213528 ("cmd64x: use interrupt status from MRDMODE register (take 2)"). Extra thanks to Martin for reporting and bisecting the issue. From: Sergei Shtylyov <sshtylyov@ru.mvista.com> Tested-by: Martin Rogge <marogge@onlinehome.de> Tested-by: Milan Kocian <milon@wq.cz> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/pci/cmd64x.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/ide/pci/cmd64x.c b/drivers/ide/pci/cmd64x.c
index ea0143ef5fe5..51fca441c294 100644
--- a/drivers/ide/pci/cmd64x.c
+++ b/drivers/ide/pci/cmd64x.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * linux/drivers/ide/pci/cmd64x.c Version 1.50 May 10, 2007 2 * linux/drivers/ide/pci/cmd64x.c Version 1.51 Nov 8, 2007
3 * 3 *
4 * cmd64x.c: Enable interrupts at initialization time on Ultra/PCI machines. 4 * cmd64x.c: Enable interrupts at initialization time on Ultra/PCI machines.
5 * Due to massive hardware bugs, UltraDMA is only supported 5 * Due to massive hardware bugs, UltraDMA is only supported
@@ -339,7 +339,8 @@ static int cmd648_ide_dma_end (ide_drive_t *drive)
339 u8 mrdmode = inb(hwif->dma_master + 0x01); 339 u8 mrdmode = inb(hwif->dma_master + 0x01);
340 340
341 /* clear the interrupt bit */ 341 /* clear the interrupt bit */
342 outb(mrdmode | irq_mask, hwif->dma_master + 0x01); 342 outb((mrdmode & ~(MRDMODE_INTR_CH0 | MRDMODE_INTR_CH1)) | irq_mask,
343 hwif->dma_master + 0x01);
343 344
344 return err; 345 return err;
345} 346}