]> git.proxmox.com Git - mirror_qemu.git/blobdiff - system/dma-helpers.c
tests/tcg: Factor out gdbstub test functions
[mirror_qemu.git] / system / dma-helpers.c
index 528117f256c533ffb0978339bec495dbef9086c3..9b221cf94e259fdfa8c487dcad10f566f2854826 100644 (file)
@@ -119,6 +119,9 @@ static void dma_blk_cb(void *opaque, int ret)
 
     trace_dma_blk_cb(dbs, ret);
 
+    /* DMAAIOCB is not thread-safe and must be accessed only from dbs->ctx */
+    assert(ctx == qemu_get_current_aio_context());
+
     dbs->acb = NULL;
     dbs->offset += dbs->iov.size;