Received: from eggs.gnu.org ([2001:4830:134:3::10]:34554) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VQcBy-0000p5-W5 for qemu-devel@nongnu.org; Mon, 30 Sep 2013 08:03:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VQcBt-0005j8-0e for qemu-devel@nongnu.org; Mon, 30 Sep 2013 08:03:10 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33808) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VQcBs-0005iu-QN for qemu-devel@nongnu.org; Mon, 30 Sep 2013 08:03:04 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r8UC33QK014520 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 30 Sep 2013 08:03:04 -0400 From: Fam Zheng Date: Mon, 30 Sep 2013 20:02:51 +0800 Message-Id: <1380542578-2387-1-git-send-email-famz@redhat.com> Subject: [Qemu-devel] [PATCH v4 0/7] block: allow commit active as top List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, pbonzini@redhat.com, jcody@redhat.com, famz@redhat.com, stefanha@redhat.com Previously live commit of active block device is not supported, this series implements it and updates corresponding qemu-iotests cases. v4: Rewrite to reuse block/mirror.c. When committing the active layer, the job is internally a mirror job with type name faked to "commit". When the job completes, the BDSes are swapped, so the base image become active and [top, base) dropped. Fam Zheng (7): block: add bdrv_common_ancestor() qmp: add internal sync mode "common" to mirror_start mirror: don't close target mirror: Add commit_job_type to perform commit with mirror code commit: support commit active layer commit: remove unused check qemu-iotests: update test cases for commit active block.c | 15 ++++++++++ block/commit.c | 7 ----- block/mirror.c | 29 +++++++++++++++--- blockdev.c | 49 +++++++++++++++++++++++++++++-- include/block/block.h | 2 ++ include/block/block_int.h | 2 ++ qapi-schema.json | 2 +- tests/qemu-iotests/040 | 73 ++++++++++++++++++++-------------------------- tests/qemu-iotests/041 | 5 ++++ tests/qemu-iotests/041.out | 4 +-- 10 files changed, 129 insertions(+), 59 deletions(-) -- 1.8.3.1