diff options
author | Luiz Capitulino <lcapitulino@redhat.com> | 2010-02-25 12:06:58 -0300 |
---|---|---|
committer | Anthony Liguori <aliguori@us.ibm.com> | 2010-03-08 11:30:01 -0600 |
commit | 1f0922207754386d5a455c95a11453316bfa1632 (patch) | |
tree | b96781b970241a3a47dfed717fec7c303d61ed47 /hw/ide | |
parent | df1eb5e2b96d2a4f9317480d53fd9e3fa6eb41c3 (diff) | |
download | qemu-1f0922207754386d5a455c95a11453316bfa1632.tar.gz qemu-1f0922207754386d5a455c95a11453316bfa1632.tar.bz2 qemu-1f0922207754386d5a455c95a11453316bfa1632.zip |
block: Emit BLOCK_IO_ERROR before vm_stop() call
The next commit will move the STOP event into do_vm_stop(), to
have the expected event sequence we need to emit the I/O error
event before calling vm_stop().
The expected sequence is:
{ "event": "BLOCK_IO_ERROR" [...] }
{ "event": "STOP" }
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'hw/ide')
-rw-r--r-- | hw/ide/core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/ide/core.c b/hw/ide/core.c index 2e0971ddeb..67480bbba9 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -491,8 +491,8 @@ static int ide_handle_rw_error(IDEState *s, int error, int op) || action == BLOCK_ERR_STOP_ANY) { s->bus->bmdma->unit = s->unit; s->bus->bmdma->status |= op; - vm_stop(0); bdrv_mon_event(s->bs, BDRV_ACTION_STOP, is_read); + vm_stop(0); } else { if (op & BM_STATUS_DMA_RETRY) { dma_buf_commit(s, 0); |