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

[Xen-changelog] [xen master] arm/traps: fix bug in dump_guest_s1_walk handling of level 2 page tables



commit a43cc8fc0827a4110b884b0fd94bf98628f27ab7
Author:     Jonathan Daugherty <jtd@xxxxxxxxxx>
AuthorDate: Wed Jul 20 09:10:17 2016 -0700
Commit:     Stefano Stabellini <sstabellini@xxxxxxxxxx>
CommitDate: Wed Jul 20 10:32:55 2016 -0700

    arm/traps: fix bug in dump_guest_s1_walk handling of level 2 page tables
    
    dump_guest_s1_walk intends to walk to level 2 page table entries but
    was failing to do so because of a check that caused level 2 page table
    descriptors to be ignored. This change fixes the check so that level 2
    page table walks occur as intended by ignoring descriptors unless their
    low two bits match the expected sequence [0,1].
    
    For more information, see the ARMv7-A ARM DDI 0406C.b, section B3.5.1.
    
    Signed-off-by: Jonathan Daugherty <jtd@xxxxxxxxxx>
    Reviewed-by: Julien Grall <julien.grall@xxxxxxx>
    Acked-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
---
 xen/arch/arm/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/arch/arm/traps.c b/xen/arch/arm/traps.c
index 0c10c4d..dfb1949 100644
--- a/xen/arch/arm/traps.c
+++ b/xen/arch/arm/traps.c
@@ -2350,7 +2350,7 @@ void dump_guest_s1_walk(struct domain *d, vaddr_t addr)
     printk("1ST[0x%"PRIx32"] (0x%"PRIpaddr") = 0x%08"PRIx32"\n",
            offset, pfn_to_paddr(mfn_x(mfn)), first[offset]);
     if ( !(first[offset] & 0x1) ||
-         !(first[offset] & 0x2) )
+          (first[offset] & 0x2) )
         goto done;
 
     mfn = p2m_lookup(d, _gfn(paddr_to_pfn(first[offset])), NULL);
--
generated by git-patchbot for /home/xen/git/xen.git#master

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxx
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®.