Commit 6a7ad2998ca47711eddd191caa1a95f14459793f

Authored by Dor Laor
Committed by Anthony Liguori
1 parent 3fe5c14e

Call qemu_bh_delete at bdrv_aio_bh_cb.

Also replave qemu_bh_cancel with qemu_bh_delete in bdrv_aio_cancel_em.
 Otherwise the bh will live forever in the bh list.

Signed-off-by: Dor Laor <dor@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Showing 1 changed file with 2 additions and 2 deletions
... ... @@ -1373,7 +1373,7 @@ typedef struct BlockDriverAIOCBSync {
1373 1373 static void bdrv_aio_cancel_em(BlockDriverAIOCB *blockacb)
1374 1374 {
1375 1375 BlockDriverAIOCBSync *acb = (BlockDriverAIOCBSync *)blockacb;
1376   - qemu_bh_cancel(acb->bh);
  1376 + qemu_bh_delete(acb->bh);
1377 1377 qemu_aio_release(acb);
1378 1378 }
1379 1379  
... ... @@ -1390,7 +1390,7 @@ static void bdrv_aio_bh_cb(void *opaque)
1390 1390 qemu_iovec_from_buffer(acb->qiov, acb->bounce, acb->qiov->size);
1391 1391 qemu_vfree(acb->bounce);
1392 1392 acb->common.cb(acb->common.opaque, acb->ret);
1393   -
  1393 + qemu_bh_delete(acb->bh);
1394 1394 qemu_aio_release(acb);
1395 1395 }
1396 1396  
... ...