From: "Jan Beulich" Subject: Re: [PATCH RFC 1/7] xen/x86: Add mbd.h header file Date: Mon, 11 Aug 2014 10:49:15 +0100 Message-ID: <53E8ADBB020000780002B0A6@mail.emea.novell.com> References: <1407539046-16910-1-git-send-email-daniel.kiper@oracle.com> <1407539046-16910-2-git-send-email-daniel.kiper@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1XGmEC-0003fv-88 for xen-devel@lists.xenproject.org; Mon, 11 Aug 2014 09:49:20 +0000 In-Reply-To: <1407539046-16910-2-git-send-email-daniel.kiper@oracle.com> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Daniel Kiper Cc: keir@xen.org, ian.campbell@citrix.com, stefano.stabellini@eu.citrix.com, roy.franz@linaro.org, ning.sun@intel.com, ross.philipson@citrix.com, xen-devel@lists.xenproject.org, qiaowei.ren@intel.com, richard.l.maliszewski@intel.com, gang.wei@intel.com, fu.wei@linaro.org List-Id: xen-devel@lists.xenproject.org >>> On 09.08.14 at 01:04, wrote: > --- /dev/null > +++ b/xen/include/asm-x86/mbd.h > @@ -0,0 +1,70 @@ > +/* > + * Copyright (c) 2013, 2014 Oracle Co., Daniel Kiper > + * > + * This program is free software; you can redistribute it and/or modify > + * it under the terms of the GNU General Public License as published by > + * the Free Software Foundation; either version 2 of the License, or > + * (at your option) any later version. > + * > + * This program is distributed in the hope that it will be useful, > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > + * GNU General Public License for more details. > + * > + * You should have received a copy of the GNU General Public License along > + * with this program. If not, see . > + */ > + > +#ifndef __MBD_H__ > +#define __MBD_H__ > + > +/* Module type. */ > +typedef struct { > + u32 start; > + u32 end; > + > + /* Pointer to a module command line. */ > + u32 cmdline; > + > + /* If relocated != 0 then a given module was relocated. */ > + u32 relocated; > +} boot_module_t; > + > +/* > + * MultiBoot Data (MBD) type. It is used to define variable which > + * carry over data from multiboot protocol (any version) through > + * Xen preloader stage. Later all or parts of this data is used > + * to initialize Xen Boot Info (XBI) structure. > + */ > +typedef struct { > + /* Pointer to boot loader name. */ > + u32 boot_loader_name; > + > + /* Pointer to Xen command line. */ > + u32 cmdline; > + > + /* > + * Amount of lower memory (in KiB) accordingly to The Multiboot > + * Specification version 0.6.96. > + */ > + u32 mem_lower; > + > + /* > + * Amount of upper memory (in KiB) accordingly to The Multiboot > + * Specification version 0.6.96. > + */ > + u32 mem_upper; > + > + /* Size (in bytes) of memory map provided by bootloader. */ > + u32 mmap_size; > + > + /* Pointer to memory map provided by bootloader. */ > + u32 mmap; > + > + /* Number of modules. */ > + u32 mods_nr; > + > + /* Pointer to modules description (boot_module_t *). */ > + u32 mods; > +} mbd_t; > +#endif /* __MBD_H__ */ For several of the fields I wonder whether u32 is really the right data type (i.e. whether u64 wouldn't be more correct going forward). Jan