From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Chen, Tiejun" Subject: Re: [v7][RFC][PATCH 04/13] hvmloader/util: get reserved device memory maps Date: Mon, 27 Oct 2014 13:07:06 +0800 Message-ID: <544DD2FA.1030508@intel.com> References: <1414136077-18599-1-git-send-email-tiejun.chen@intel.com> <1414136077-18599-5-git-send-email-tiejun.chen@intel.com> <544A7DED0200007800041FE0@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <544A7DED0200007800041FE0@mail.emea.novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Jan Beulich Cc: yang.z.zhang@intel.com, kevin.tian@intel.com, tim@xen.org, xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On 2014/10/24 22:27, Jan Beulich wrote: >>>> On 24.10.14 at 09:34, wrote: >> --- a/tools/firmware/hvmloader/util.h >> +++ b/tools/firmware/hvmloader/util.h >> @@ -241,6 +241,12 @@ int build_e820_table(struct e820entry *e820, >> unsigned int bios_image_base); >> void dump_e820_table(struct e820entry *e820, unsigned int nr); >> >> +#include >> +#define ENOBUFS 105 /* No buffer space available */ >> +struct xen_mem_reserved_device_memory *rdm_map; > > Oh, and - without "extern" this creates an instance in each > translation unit (and would cause build failures the moment > someone passed -fno-common to the compiler). > So instead, just define this in util.c then use this with 'extern'. Thanks Tiejun