Fix bugs in the ATAPI cdrom driver, by Brandon Philips.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3124 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
c0009975ca
commit
7603d1568e
2
hw/ide.c
2
hw/ide.c
|
@ -671,6 +671,7 @@ static void ide_transfer_start(IDEState *s, uint8_t *buf, int size,
|
|||
s->end_transfer_func = end_transfer_func;
|
||||
s->data_ptr = buf;
|
||||
s->data_end = buf + size;
|
||||
if (!(s->status & ERR_STAT))
|
||||
s->status |= DRQ_STAT;
|
||||
}
|
||||
|
||||
|
@ -1969,6 +1970,7 @@ static void ide_ioport_write(void *opaque, uint32_t addr, uint32_t val)
|
|||
/* overlapping commands not supported */
|
||||
if (s->feature & 0x02)
|
||||
goto abort_cmd;
|
||||
s->status = READY_STAT;
|
||||
s->atapi_dma = s->feature & 1;
|
||||
s->nsector = 1;
|
||||
ide_transfer_start(s, s->io_buffer, ATAPI_PACKET_SIZE,
|
||||
|
|
Loading…
Reference in a new issue