ide: Set bus master inactive on error

BMIDEA in the status register must be cleared on error. This makes FreeBSD
respond (more) correctly to I/O errors.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
This commit is contained in:
Kevin Wolf 2010-11-26 16:47:42 +01:00
parent 8337606d35
commit e3982b3cf6

View File

@ -486,6 +486,8 @@ void ide_dma_error(IDEState *s)
ide_transfer_stop(s); ide_transfer_stop(s);
s->error = ABRT_ERR; s->error = ABRT_ERR;
s->status = READY_STAT | ERR_STAT; s->status = READY_STAT | ERR_STAT;
ide_dma_set_inactive(s->bus->bmdma);
s->bus->bmdma->status |= BM_STATUS_INT;
ide_set_irq(s->bus); ide_set_irq(s->bus);
} }