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

Re: [Xen-devel] [PATCH v10 01/12] arch/arm: add consistency check to REMOVE p2m changes



On Tue, 2014-07-29 at 12:55 +0100, Julien Grall wrote:

> > -                return P2M_ONE_DESCEND;
> > +                 if ( is_mapping_aligned(*addr, end_gpaddr, *maddr, 
> > level_size) )
> > +                 {
> 
> You don't cover every case with this solution. This code is only called
> when (level < 3). So for single 4k (level 3), Xen will not print a
> message when the MFN differ.
> 
> I still think that the best place to check it, is after the if ( level < 3 )
> 
> The code would look like:
> 
> if ( level < 3 )
> {
>   ....
> }
> 
> if ( op == REMOVE && pfn_to_paddr(orig_pte.p2m.base) != *maddr )
>       printk(XENLOG_ERR "p2m_remove"....);

I agree, and this suggestion looks correct to me.

Ian.


_______________________________________________
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®.