Received: from eggs.gnu.org ([2001:4830:134:3::10]:46023) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cw8MM-0005aG-PL for qemu-devel@nongnu.org; Thu, 06 Apr 2017 10:26:03 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cw8MM-0001le-3e for qemu-devel@nongnu.org; Thu, 06 Apr 2017 10:26:02 -0400 From: Fam Zheng Date: Thu, 6 Apr 2017 22:25:24 +0800 Message-Id: <20170406142527.25835-3-famz@redhat.com> In-Reply-To: <20170406142527.25835-1-famz@redhat.com> References: <20170406142527.25835-1-famz@redhat.com> Subject: [Qemu-devel] [PATCH for-2.9 2/5] mirror: Fix aio context of mirror_top_bs List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , qemu-block@nongnu.org, Ed Swierk , Fam Zheng , Kevin Wolf , Max Reitz , Stefan Hajnoczi It should be moved to the same context as source, before inserting to the graph. Signed-off-by: Fam Zheng --- block/mirror.c | 1 + 1 file changed, 1 insertion(+) diff --git a/block/mirror.c b/block/mirror.c index 9e2fecc..e904fef 100644 --- a/block/mirror.c +++ b/block/mirror.c @@ -1148,6 +1148,7 @@ static void mirror_start_job(const char *job_id, BlockDriverState *bs, return; } mirror_top_bs->total_sectors = bs->total_sectors; + bdrv_set_aio_context(mirror_top_bs, bdrv_get_aio_context(bs)); /* bdrv_append takes ownership of the mirror_top_bs reference, need to keep * it alive until block_job_create() even if bs has no parent. */ -- 2.9.3