]> xenbits.xensource.com Git - people/sstabellini/xen-unstable.git/.git/commitdiff
xen/arm32: mm: Avoid to zero and clean cache for CPU0 domheap
authorJulien Grall <julien.grall@arm.com>
Sun, 7 Apr 2019 19:59:22 +0000 (20:59 +0100)
committerJulien Grall <julien.grall@arm.com>
Thu, 6 Jun 2019 17:44:33 +0000 (18:44 +0100)
The page-table walker is configured to use the same shareability and
cacheability as the access performed when updating the page-tables. This
means cleaning the cache for CPU0 domheap is unnecessary.

Furthermore, CPU0 page-tables are part of Xen binary and will already be
zeroed before been used. So it is pointless to zero the domheap again.

Signed-off-by: Julien Grall <julien.grall@arm.com>
Reviewed-by: Andrii Anisov <andrii_anisov@epam.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
xen/arch/arm/mm.c

index bd1942f7f12b30b2801164729cd8db14c363d794..ee72fb5e8fabd764f72d53687097b89ef7f84afa 100644 (file)
@@ -696,11 +696,6 @@ void __init setup_pagetables(unsigned long boot_phys_offset)
 #ifdef CONFIG_ARM_32
     per_cpu(xen_pgtable, 0) = cpu0_pgtable;
     per_cpu(xen_dommap, 0) = cpu0_dommap;
-
-    /* Make sure it is clear */
-    memset(this_cpu(xen_dommap), 0, DOMHEAP_SECOND_PAGES*PAGE_SIZE);
-    clean_dcache_va_range(this_cpu(xen_dommap),
-                              DOMHEAP_SECOND_PAGES*PAGE_SIZE);
 #endif
 }