[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1294305390.3831.3593.camel@zakaz.uk.xensource.com>
Date: Thu, 6 Jan 2011 09:16:30 +0000
From: Ian Campbell <Ian.Campbell@...citrix.com>
To: Konrad Rzeszutek Wilk <konrad.wilk@...cle.com>
CC: Stefano Stabellini <Stefano.Stabellini@...citrix.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"xen-devel@...ts.xensource.com" <xen-devel@...ts.xensource.com>,
"Jeremy Fitzhardinge" <Jeremy.Fitzhardinge@...rix.com>
Subject: Re: [PATCH 01/11] xen: define gnttab_set_map_op/unmap_op
On Wed, 2011-01-05 at 20:25 +0000, Konrad Rzeszutek Wilk wrote:
> On Wed, Dec 15, 2010 at 01:40:36PM +0000, stefano.stabellini@...citrix.com wrote:
> > +static inline void
> > +gnttab_set_map_op(struct gnttab_map_grant_ref *map, phys_addr_t addr,
> > + uint32_t flags, grant_ref_t ref, domid_t domid)
> > +{
> > + if (flags & GNTMAP_contains_pte)
> > + map->host_addr = addr;
> > + else if (xen_feature(XENFEAT_auto_translated_physmap))
> > + map->host_addr = __pa(addr);
> > + else
> > + map->host_addr = addr;
>
> Why not just get rid of the "flags & GNTMAP_contains_pte"? If
> that returns false you still end up setting map->host_addr to addr.
That would behave differently if
xen_feature(XENFEAT_auto_translated_physmap) were true.
Ian.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists