From patchwork Tue Nov 13 15:51:27 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2/4] megasas: Use bdrv_drain_all instead of qemu_aio_flush Date: Tue, 13 Nov 2012 05:51:27 -0000 From: Kevin Wolf X-Patchwork-Id: 198710 Message-Id: <1352821889-24150-3-git-send-email-kwolf@redhat.com> To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, pbonzini@redhat.com Calling qemu_aio_flush() directly can hang when combined with I/O throttling. Signed-off-by: Kevin Wolf --- hw/megasas.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/megasas.c b/hw/megasas.c index 7a2036e..d332d41 100644 --- a/hw/megasas.c +++ b/hw/megasas.c @@ -1296,7 +1296,7 @@ static int megasas_dcmd_get_properties(MegasasState *s, MegasasCmd *cmd) static int megasas_cache_flush(MegasasState *s, MegasasCmd *cmd) { - qemu_aio_flush(); + bdrv_drain_all(); return MFI_STAT_OK; }