aboutsummaryrefslogtreecommitdiff
path: root/hw/ide/core.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/ide/core.c')
-rw-r--r--hw/ide/core.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/hw/ide/core.c b/hw/ide/core.c
index 49847bd3ea..de9ed411a2 100644
--- a/hw/ide/core.c
+++ b/hw/ide/core.c
@@ -549,7 +549,6 @@ void ide_dma_cb(void *opaque, int ret)
int n;
int64_t sector_num;
-handle_rw_error:
if (ret < 0) {
int op = BM_STATUS_DMA_RETRY;
@@ -608,11 +607,6 @@ handle_rw_error:
ide_issue_trim, ide_dma_cb, s, true);
break;
}
-
- if (!s->bus->dma->aiocb) {
- ret = -1;
- goto handle_rw_error;
- }
return;
eot:
@@ -718,18 +712,13 @@ static void ide_flush_cb(void *opaque, int ret)
void ide_flush_cache(IDEState *s)
{
- BlockDriverAIOCB *acb;
-
if (s->bs == NULL) {
ide_flush_cb(s, 0);
return;
}
bdrv_acct_start(s->bs, &s->acct, 0, BDRV_ACCT_FLUSH);
- acb = bdrv_aio_flush(s->bs, ide_flush_cb, s);
- if (acb == NULL) {
- ide_flush_cb(s, -EIO);
- }
+ bdrv_aio_flush(s->bs, ide_flush_cb, s);
}
static void ide_cfata_metadata_inquiry(IDEState *s)