qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 4/5] block: cow - used QEMU_PACKED for on-disk s


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH 4/5] block: cow - used QEMU_PACKED for on-disk structures
Date: Wed, 25 Sep 2013 12:39:48 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8

On 09/25/2013 12:01 PM, Jeff Cody wrote:
> It is from UML, right?  Is there an official spec that is still around
> (most of the links I have found suffer from link rot)?  The closest I
> could find to a spec were old UML patches for x86_64 that cleaned up
> some data types, so that the following was defined:
> 
> struct cow_header_v2 {                                                        
>                                             
>    __u32 magic;
>    __u32 version;
>    char backing_file[PATH_LEN_V2];
>    time_t mtime;
>    __u64 size;
>    int sectorsize;
> };
> 
> That remains ambiguous, although given the era I suppose it could be
> argued that 32-bit architecture and alignment is assumed.  But if this
> is the original spec, then it seems like a non-portable one.

Indeed.  Not just the potential padding there, but of course
the size of time_t varies between hosts.  And since we use
an int32_t not time_t, we're not even necessarily compatible
with UML.


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]