Skip to content

Commit f693be4

Browse files
Sergei Shtylyovdavem330
authored andcommitted
pdc202xx_old: ignore "FIFO empty" bit in test_irq() method
The driver takes into account not only the interrupt status bit but also "FIFO empty" bit in its test_irq() method. This actually is a superfluous check since for the DMA commands calling the dma_test_irq() method further in the interrupt handler makes sure FIFO is emptied. Signed-off-by: Sergei Shtylyov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 63e7cf9 commit f693be4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/ide/pdc202xx_old.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,13 @@ static int pdc202xx_test_irq(ide_hwif_t *hwif)
9393
* bit 7: error, bit 6: interrupting,
9494
* bit 5: FIFO full, bit 4: FIFO empty
9595
*/
96-
return ((sc1d & 0x50) == 0x50) ? 1 : 0;
96+
return (sc1d & 0x40) ? 1 : 0;
9797
} else {
9898
/*
9999
* bit 3: error, bit 2: interrupting,
100100
* bit 1: FIFO full, bit 0: FIFO empty
101101
*/
102-
return ((sc1d & 0x05) == 0x05) ? 1 : 0;
102+
return (sc1d & 0x04) ? 1 : 0;
103103
}
104104
}
105105

0 commit comments

Comments
 (0)