From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49118) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V55Jh-00024p-P4 for qemu-devel@nongnu.org; Thu, 01 Aug 2013 22:42:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V55Jb-0003W2-O8 for qemu-devel@nongnu.org; Thu, 01 Aug 2013 22:42:09 -0400 Received: from mx1.redhat.com ([209.132.183.28]:1592) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V51OT-0003cY-Qr for qemu-devel@nongnu.org; Thu, 01 Aug 2013 18:30:50 -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 r71MUlRW007063 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 1 Aug 2013 18:30:49 -0400 Date: Thu, 1 Aug 2013 17:00:05 +0200 From: Stefan Hajnoczi Message-ID: <20130801150005.GE2387@stefanha-thinkpad.redhat.com> References: <9e47d3ea77357b438ce2164f6e226d216553c58e.1375325971.git.jcody@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9e47d3ea77357b438ce2164f6e226d216553c58e.1375325971.git.jcody@redhat.com> Subject: Re: [Qemu-devel] [PATCH v2 4/9] block: vhdx - log support struct and defines List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jeff Cody Cc: kwolf@redhat.com, famz@redhat.com, qemu-devel@nongnu.org On Wed, Jul 31, 2013 at 11:23:49PM -0400, Jeff Cody wrote: > @@ -318,6 +323,18 @@ typedef struct VHDXMetadataEntries { > uint16_t present; > } VHDXMetadataEntries; > > +typedef struct VHDXLogEntries { > + uint64_t offset; > + uint64_t length; > + uint32_t head; > + uint32_t tail; > +} VHDXLogEntries; > + > +typedef struct VHDXLogEntryInfo { > + uint64_t sector_start; > + uint32_t desc_count; > +} VHDXLogEntryInfo; An array of VHDXLogEntryInfo structs would be affected by alignment on x86_64. &a[1] != (void*)a + sizeof(VHDXLogEntryInfo). IMO all on-disk structs should be QEMU_PACKED for safety.