Received: from eggs.gnu.org ([208.118.235.92]:44360) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbczL-0006rO-Kr for qemu-devel@nongnu.org; Thu, 22 Nov 2012 15:03:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TbczK-0005Uh-K2 for qemu-devel@nongnu.org; Thu, 22 Nov 2012 15:03:07 -0500 Received: from e06smtp15.uk.ibm.com ([195.75.94.111]:53930) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbczK-0005TT-9g for qemu-devel@nongnu.org; Thu, 22 Nov 2012 15:03:06 -0500 Received: from /spool/local by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 22 Nov 2012 20:03:04 -0000 Received: from d06av01.portsmouth.uk.ibm.com (d06av01.portsmouth.uk.ibm.com [9.149.37.212]) by b06cxnps3074.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id qAMK2swp65208552 for ; Thu, 22 Nov 2012 20:02:54 GMT Received: from d06av01.portsmouth.uk.ibm.com (loopback [127.0.0.1]) by d06av01.portsmouth.uk.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id qAMK31Aa028543 for ; Thu, 22 Nov 2012 13:03:01 -0700 From: Christian Borntraeger Date: Thu, 22 Nov 2012 21:02:56 +0100 Message-Id: <1353614576-21015-3-git-send-email-borntraeger@de.ibm.com> In-Reply-To: <1353614576-21015-1-git-send-email-borntraeger@de.ibm.com> References: <877gpdybqr.fsf@blackfin.pond.sub.org> <1353614576-21015-1-git-send-email-borntraeger@de.ibm.com> Subject: [Qemu-devel] [PATCH 2/2] block: clarify comment about IF_IDE = 0 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: Kevin Wolf , Peter Maydell , Anthony Liguori , Igor Mitsyanko , qemu-devel , Alexander Graf , Christian Borntraeger , Jens Freimann , Stefan Hajnoczi , Cornelia Huck , Andreas Faerber , Einar Lueck Lets make the comment regarding IF_IDE more precise why it must be 0. Signed-off-by: Christian Borntraeger --- blockdev.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/blockdev.h b/blockdev.h index 1c9ca6a..d73d552 100644 --- a/blockdev.h +++ b/blockdev.h @@ -19,7 +19,11 @@ void blockdev_auto_del(BlockDriverState *bs); typedef enum { IF_DEFAULT = -1, /* for use with drive_add() only */ - IF_IDE, /* machines without block_default_type get 0 */ + /* + * IF_IDE must be zero, because we want QEMUMachine member + * block_default_type to default-initialize to IF_IDE + */ + IF_IDE = 0, IF_NONE, IF_SCSI, IF_FLOPPY, IF_PFLASH, IF_MTD, IF_SD, IF_VIRTIO, IF_XEN, IF_COUNT -- 1.7.9.5