From: Ian Campbell Subject: Re: Re: [PATCH] xen: reduce severity of message about using v1 grant tables. Date: Thu, 3 Dec 2009 21:23:45 +0000 Message-ID: <1259875425.31045.119.camel@localhost.localdomain> References: <1259782098-32180-1-git-send-email-Ian.Campbell@citrix.com> <4B16C103.9070105@goop.org> <1259783682.31045.22.camel@localhost.localdomain> <1259836124.23698.10393.camel@zakaz.uk.xensource.com> <20091203120116.GA15460@weybridge.uk.xensource.com> <4B181C06.7040107@goop.org> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4B181C06.7040107@goop.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jeremy Fitzhardinge Cc: Steven Smith , "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On Thu, 2009-12-03 at 20:13 +0000, Jeremy Fitzhardinge wrote: > > > BUG_ON(flags & (GTF_accept_transfer | GTF_reading | > > GTF_writing | GTF_sub_page | > GTF_permit_access)); > > - BUG_ON(grant_table_version == 1); > > + if (grant_table_version == 1) > > > > Rather than having all these version tests, would it make sense to > have a grant_ops vector? I was looking at these today and reckon you could go a long way with a couple of accessor macros towards avoiding most of the version checks. Ian.