/* ICHx contollers set DMA INTR no matter DMA or PIO. BMDMA status might need to be cleared even for PIO interrupts to prevent spurious/lost IRQ.  */
static void ich_clear_irq(ide_drive_t *drive)
/* ICHx contollers set DMA INTR no matter DMA or PIO. BMDMA status might need to be cleared even for PIO interrupts to prevent spurious/lost IRQ.  */
static void ich_clear_irq(ide_drive_t *drive)
{
	ide_hwif_t *hwif = drive->hwif;
	u8 dma_stat;
	if (drive->waiting_for_dma || hwif->dma_base == 0)
		return;
	dma_stat = inb(hwif->dma_base + ATA_DMA_STATUS);
	outb(dma_stat, hwif->dma_base + ATA_DMA_STATUS);
}