j
: Next unread message k
: Previous unread message j a
: Jump to all threads
j l
: Jump to MailingList overview
Author: blueswirl Date: 2010-01-16 09:47:39 +0100 (Sat, 16 Jan 2010) New Revision: 665
Modified: trunk/openbios-devel/drivers/esp.c Log: ESP: fix spurious guest interrupts during boot
Signed-off-by: Blue Swirl blauwirbel@gmail.com
Modified: trunk/openbios-devel/drivers/esp.c =================================================================== --- trunk/openbios-devel/drivers/esp.c 2010-01-10 18:26:34 UTC (rev 664) +++ trunk/openbios-devel/drivers/esp.c 2010-01-16 08:47:39 UTC (rev 665) @@ -101,6 +101,9 @@ esp->ll->regs[ESP_CMD] = ESP_CMD_SELA | ESP_CMD_DMA; // Wait for DMA to complete. Can this fail? while ((esp->espdma.regs->cond_reg & DMA_HNDL_INTR) == 0) /* no-op */; + // Clear interrupts to avoid guests seeing spurious interrupts + (void)esp->ll->regs[ESP_INTRPT]; + // Check status status = esp->ll->regs[ESP_STATUS];
@@ -124,6 +127,10 @@ esp->ll->regs[ESP_CMD] = ESP_CMD_TI | ESP_CMD_DMA; // Wait for DMA to complete while ((esp->espdma.regs->cond_reg & DMA_HNDL_INTR) == 0) /* no-op */; + + // Clear interrupts to avoid guests seeing spurious interrupts + (void)esp->ll->regs[ESP_INTRPT]; + // Check status status = esp->ll->regs[ESP_STATUS];