[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH RFC v2 07/12] x86: allow per-domain mappings without NX bit or with specific mfn
>>> On 30.01.18 at 09:02, <jgross@xxxxxxxx> wrote: > On 29/01/18 18:06, Jan Beulich wrote: >>>>> On 22.01.18 at 13:32, <jgross@xxxxxxxx> wrote: >>> --- a/xen/arch/x86/mm.c >>> +++ b/xen/arch/x86/mm.c >>> @@ -1568,7 +1568,7 @@ void init_xen_l4_slots(l4_pgentry_t *l4t, mfn_t l4mfn, >>> >>> /* Slot 260: Per-domain mappings (if applicable). */ >>> l4t[l4_table_offset(PERDOMAIN_VIRT_START)] = >>> - d ? l4e_from_page(d->arch.perdomain_l3_pg, __PAGE_HYPERVISOR_RW) >>> + d ? l4e_from_page(d->arch.perdomain_l3_pg, __PAGE_HYPERVISOR) >>> : l4e_empty(); >>> >>> /* Slot 261-: text/data/bss, RW M2P, vmap, frametable, directmap. */ >>> @@ -5269,7 +5269,7 @@ int create_perdomain_mapping(struct domain *d, >>> unsigned long va, >>> } >>> l2tab = __map_domain_page(pg); >>> clear_page(l2tab); >>> - l3tab[l3_table_offset(va)] = l3e_from_page(pg, >>> __PAGE_HYPERVISOR_RW); >>> + l3tab[l3_table_offset(va)] = l3e_from_page(pg, __PAGE_HYPERVISOR); >>> } >>> else >>> l2tab = map_l2t_from_l3e(l3tab[l3_table_offset(va)]); >>> @@ -5311,7 +5311,7 @@ int create_perdomain_mapping(struct domain *d, >>> unsigned long va, >>> l1tab = __map_domain_page(pg); >>> } >>> clear_page(l1tab); >>> - *pl2e = l2e_from_page(pg, __PAGE_HYPERVISOR_RW); >>> + *pl2e = l2e_from_page(pg, __PAGE_HYPERVISOR); >> >> These changes (in the absence of the description saying otherwise) >> leave open whether any of the per-domain mappings now suddenly >> become executable. > > Are you fine with me adding something like the following to the commit > message: > > As create_perdomain_mapping() creates L1 mappings with flags being > __PAGE_HYPERVISOR_RW this won't change any of the current per domain > mappings to become executable. That would seem to be sufficient, yes. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |