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

Re: [Xen-devel] [PATCH v7.2 07/24] x86/mm: Introduce modify_xen_mappings()



On 11/04/16 18:54, Jan Beulich wrote:
>>>> On 11.04.16 at 19:46, <andrew.cooper3@xxxxxxxxxx> wrote:
>> To simply change the permissions on existing Xen mappings.  The existing
>> destroy_xen_mappings() is altered to support a change the PTE permissions.
>>
>> A new destroy_xen_mappings() is introduced, as the special case of not 
>> passing
>> _PAGE_PRESENT to modify_xen_mappings().
>>
>> As cleanup (and an ideal functional test), the boot logic which remaps Xen's
>> code and data with reduced permissions is altered to use
>> modify_xen_mappings(), rather than map_pages_to_xen() passing the same mfn's
>> back in.
>>
>> Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
> Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
> with one remark:
>
>> -            /* If we are done with the L2E, check if it is now empty. */
>> -            if ( (v != e) && (l1_table_offset(v) != 0) )
>> +            /*
>> +             * If we not destroying mappings, or are not done with the L2E,
>> +             * skip the empty&free check.
>> +             */
>> +            if ( (nf & _PAGE_PRESENT) || ((v != e) && (l1_table_offset(v) 
>> != 0)) )
> I guess the missing "are" in the two instances of this comment
> can be folded in while committing.

Oops yes.  I did intend an "are" in there.

~Andrew

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