[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [RFC PATCH 14/16]: PVH xen: add xenmem_add_foreign_to_pmap()



At 18:18 -0800 on 11 Feb (1360606704), Mukesh Rathor wrote:
> > > +        if (!is_hvm_domain(fdom)) {
> > > +            printk("mmio type for non-hvm domain. fd:%d fgmfn:%lx
> > > gpfn:%lx\n",
> > > +                   foreign_domid, fgmfn, gpfn);
> > > +            return -EINVAL;
> > > +        }
> > > +        mfn = fgmfn;     /* map 1 to 1 */
> > 
> > Surely not -- you want to map the _actual_ MMIO range, right, not just
> > whatever GFN-address the foreigh domain mapped it at?
> 
> Actually, fgmfn here is the machine address of the mmio page. 

I hope not!  You've just passed it to a p2m lookup a little earlier, so
it had better be a gfn.  (And in either case it could do with a more
explicit name: maybe fmfn if it's an mfn or fgfn if it's a gfn?

Tim.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.