From: Wei Liu Subject: Re: [PATCH 04/16] Move event channel macros / struct definition to proper place Date: Mon, 4 Feb 2013 10:25:15 +0000 Message-ID: <1359973515.7477.15.camel@zion.uk.xensource.com> References: <1359643384-29392-1-git-send-email-wei.liu2@citrix.com> <1359643384-29392-5-git-send-email-wei.liu2@citrix.com> <510F86CE02000078000BB665@nat28.tlf.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <510F86CE02000078000BB665@nat28.tlf.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: "xen-devel@lists.xen.org" , wei.liu2@citrix.com, David Vrabel , Ian Campbell List-Id: xen-devel@lists.xenproject.org On Mon, 2013-02-04 at 09:00 +0000, Jan Beulich wrote: > >>> On 31.01.13 at 15:42, Wei Liu wrote: > > --- a/xen/include/public/xen.h > > +++ b/xen/include/public/xen.h > > @@ -557,6 +557,8 @@ DEFINE_XEN_GUEST_HANDLE(multicall_entry_t); > > * 1024 if a long is 32 bits; 4096 if a long is 64 bits. > > */ > > #define NR_EVENT_CHANNELS (sizeof(unsigned long) * sizeof(unsigned long) * 64) > > +#define EVTCHNS_PER_BUCKET 128 > > +#define NR_EVTCHN_BUCKETS (NR_EVENT_CHANNELS / EVTCHNS_PER_BUCKET) > > These aren't part of the hypercall ABI, and hence don't belong here. > What is preventing you from putting them alongside the other > stuff you move to xen/include/xen/event.h? > That would cause circular inclusion and break the build. a) sched.h: struct domain reference NR_EVTCHN_BUCKETS b) event.h: refereces sched.h Now a second thought come to me, a clean fix would be that I make the allocation of evtchn in struct domain first, then move those macros / definitions to proper place. Wei.