From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40350) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WMubE-0005sZ-PD for qemu-devel@nongnu.org; Mon, 10 Mar 2014 03:26:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WMub9-00074c-Ol for qemu-devel@nongnu.org; Mon, 10 Mar 2014 03:26:12 -0400 Received: from mx1.redhat.com ([209.132.183.28]:30233) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WMub9-00074Y-GP for qemu-devel@nongnu.org; Mon, 10 Mar 2014 03:26:07 -0400 From: Fam Zheng Date: Mon, 10 Mar 2014 15:25:57 +0800 Message-Id: <1394436370-8908-2-git-send-email-famz@redhat.com> In-Reply-To: <1394436370-8908-1-git-send-email-famz@redhat.com> References: <1394436370-8908-1-git-send-email-famz@redhat.com> Subject: [Qemu-devel] [PATCH v17 01/14] block: Add BlockOpType enum List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, benoit.canet@irqsave.net, rjones@redhat.com, jcody@redhat.com, armbru@redhat.com, ptoscano@redhat.com, imain@redhat.com, stefanha@redhat.com, pbonzini@redhat.com This adds the enum of all the operations that can be taken on a block device. Signed-off-by: Fam Zheng Reviewed-by: Benoit Canet --- include/block/block.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/include/block/block.h b/include/block/block.h index 780f48b..8820735 100644 --- a/include/block/block.h +++ b/include/block/block.h @@ -154,6 +154,25 @@ typedef struct BDRVReopenState { void *opaque; } BDRVReopenState; +/* + * Block operation types + */ +typedef enum BlockOpType { + BLOCK_OP_TYPE_BACKUP_SOURCE, + BLOCK_OP_TYPE_BACKUP_TARGET, + BLOCK_OP_TYPE_CHANGE, + BLOCK_OP_TYPE_COMMIT, + BLOCK_OP_TYPE_DATAPLANE, + BLOCK_OP_TYPE_DRIVE_DEL, + BLOCK_OP_TYPE_EJECT, + BLOCK_OP_TYPE_EXTERNAL_SNAPSHOT, + BLOCK_OP_TYPE_INTERNAL_SNAPSHOT, + BLOCK_OP_TYPE_INTERNAL_SNAPSHOT_DELETE, + BLOCK_OP_TYPE_MIRROR, + BLOCK_OP_TYPE_RESIZE, + BLOCK_OP_TYPE_STREAM, + BLOCK_OP_TYPE_MAX, +} BlockOpType; void bdrv_iostatus_enable(BlockDriverState *bs); void bdrv_iostatus_reset(BlockDriverState *bs); -- 1.9.0