[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 5/7] virtio-blk: Schedule BH in the right context
From: |
Fam Zheng |
Subject: |
[Qemu-devel] [PATCH v2 5/7] virtio-blk: Schedule BH in the right context |
Date: |
Tue, 17 Jun 2014 14:32:08 +0800 |
The BH must be called in the AioContext of bs. Currently it is only the
main loop, but with coming changes, it could also be a dataplane
IOThread.
Signed-off-by: Fam Zheng <address@hidden>
---
hw/block/virtio-blk.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c
index 25c3812..ca09bb4 100644
--- a/hw/block/virtio-blk.c
+++ b/hw/block/virtio-blk.c
@@ -469,7 +469,8 @@ static void virtio_blk_dma_restart_cb(void *opaque, int
running,
}
if (!s->bh) {
- s->bh = qemu_bh_new(virtio_blk_dma_restart_bh, s);
+ s->bh = aio_bh_new(bdrv_get_aio_context(s->blk.conf.bs),
+ virtio_blk_dma_restart_bh, s);
qemu_bh_schedule(s->bh);
}
}
--
2.0.0
- [Qemu-devel] [PATCH v2 0/7] virtio-blk: Unify request handling of dataplane, Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 1/7] block: make bdrv_query_stats() static, Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 2/7] block: acquire AioContext in qmp_query_blockstats(), Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 3/7] virtio-blk: Make request completion function virtual, Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 4/7] virtio-blk: Export request handling functions to dataplane, Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 5/7] virtio-blk: Schedule BH in the right context,
Fam Zheng <=
- [Qemu-devel] [PATCH v2 6/7] virtio-blk: Unify {non-, }dataplane's request handlings, Fam Zheng, 2014/06/17
- [Qemu-devel] [PATCH v2 7/7] virtio-blk: Rename complete_request_early to complete_request_vring, Fam Zheng, 2014/06/17
- Re: [Qemu-devel] [PATCH v2 0/7] virtio-blk: Unify request handling of dataplane, Paolo Bonzini, 2014/06/17
- Re: [Qemu-devel] [PATCH v2 0/7] virtio-blk: Unify request handling of dataplane, Stefan Hajnoczi, 2014/06/27