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

[Xen-changelog] [xen master] xen/arm: mm: Use pte_xen_addr when creating xen entries



commit e72745671a42e7f11a9418533763d210d3f0c835
Author:     Julien Grall <julien.grall@xxxxxxx>
AuthorDate: Fri Dec 14 11:44:54 2018 +0000
Commit:     Julien Grall <julien.grall@xxxxxxx>
CommitDate: Mon Dec 17 09:58:40 2018 +0000

    xen/arm: mm: Use pte_xen_addr when creating xen entries
    
    The helper pte_xen_addr computes the MFN based on the virtual
    address and generates the PTE. This can be r
    
    At the same time, make va a vaddr_t to make clear it holds virtual address.
    
    Signed-off-by: Julien Grall <julien.grall@xxxxxxx>
---
 xen/arch/arm/mm.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c
index 2556e57a99..91f3aef93c 100644
--- a/xen/arch/arm/mm.c
+++ b/xen/arch/arm/mm.c
@@ -652,12 +652,11 @@ void __init setup_pagetables(unsigned long 
boot_phys_offset, paddr_t xen_paddr)
     /* Break up the Xen mapping into 4k pages and protect them separately. */
     for ( i = 0; i < LPAE_ENTRIES; i++ )
     {
-        mfn_t mfn = mfn_add(maddr_to_mfn(xen_paddr), i);
-        unsigned long va = XEN_VIRT_START + (i << PAGE_SHIFT);
+        vaddr_t va = XEN_VIRT_START + (i << PAGE_SHIFT);
 
         if ( !is_kernel(va) )
             break;
-        pte = mfn_to_xen_entry(mfn, MT_NORMAL);
+        pte = pte_of_xenaddr(va);
         pte.pt.table = 1; /* 4k mappings always have this bit set */
         if ( is_kernel_text(va) || is_kernel_inittext(va) )
         {
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

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