From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: headers.chk failing under certain circumstances. Date: Tue, 13 Dec 2011 14:34:25 +0000 Message-ID: <4EE76271.7090509@citrix.com> References: <4EE76C7E0200007800067541@nat28.tlf.novell.com> <4EE76E7D020000780006758F@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4EE76E7D020000780006758F@nat28.tlf.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jan Beulich , "Keir (Xen.org)" Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On 13/12/11 14:25, Jan Beulich wrote: >>>> On 13.12.11 at 15:21, Keir Fraser wrote: >> On 13/12/2011 14:17, "Jan Beulich" wrote: >> >>>> Given that uint64_aligned_t is a >>>> sensible datatype to be using with the hypercall interface, fixing the >>>> check seems to be the correct solution. >>> Sensible or not, you would have to find a way to define such a type >>> in a compiler-independent (i.e. ANSI conforming) manner, and I'm >>> afraid you won't be able to. >> Yes, as barbaric as it may seem you just have to make sure that uint64_t >> gets naturally 8-byte aligned. Luckily none of our interface structures are >> particularly large, and I believe you can get them checked for 32/64-bit >> invariance by adding them to xlat.lst. > ... and invoking the resultant check macro somewhere in the sources. > > Jan Righ ok. Thanks for the explanation. Luckily, it appears that all my uint64_t's do actually align on 8 bytes so I will just use that. -- Andrew Cooper - Dom0 Kernel Engineer, Citrix XenServer T: +44 (0)1223 225 900, http://www.citrix.com