summaryrefslogtreecommitdiffstats
path: root/hw/ide/macio.c
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2011-11-30 09:12:30 +0100
committerKevin Wolf <kwolf@redhat.com>2011-12-15 12:40:07 +0100
commitad54ae80c73f486cf39b4b38a04b76dd971cdbf6 (patch)
tree68c7bc557d325ed840ae11332b69c1ecb63e32fd /hw/ide/macio.c
parent222f23f508a8d778f56eddef14752dfd26d225b4 (diff)
downloadhqemu-ad54ae80c73f486cf39b4b38a04b76dd971cdbf6.zip
hqemu-ad54ae80c73f486cf39b4b38a04b76dd971cdbf6.tar.gz
block: bdrv_aio_* do not return NULL
Initially done with the following semantic patch: @ rule1 @ expression E; statement S; @@ E = ( bdrv_aio_readv | bdrv_aio_writev | bdrv_aio_flush | bdrv_aio_discard | bdrv_aio_ioctl ) (...); ( - if (E == NULL) { ... } | - if (E) { <... S ...> } ) which however missed the occurrence in block/blkverify.c (as it should have done), and left behind some unused variables. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'hw/ide/macio.c')
-rw-r--r--hw/ide/macio.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/hw/ide/macio.c b/hw/ide/macio.c
index c09d2e0..40f60f0 100644
--- a/hw/ide/macio.c
+++ b/hw/ide/macio.c
@@ -84,13 +84,6 @@ static void pmac_ide_atapi_transfer_cb(void *opaque, int ret)
m->aiocb = dma_bdrv_read(s->bs, &s->sg,
(int64_t)(s->lba << 2) + (s->io_buffer_index >> 9),
pmac_ide_atapi_transfer_cb, io);
- if (!m->aiocb) {
- qemu_sglist_destroy(&s->sg);
- /* Note: media not present is the most likely case */
- ide_atapi_cmd_error(s, NOT_READY,
- ASC_MEDIUM_NOT_PRESENT);
- goto done;
- }
return;
done:
OpenPOWER on IntegriCloud