[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [PATCH v3 07/19] xen/arm: mm: Don't open-code Xen PT update in remove_early_mappings()
From: Julien Grall <julien.grall@xxxxxxx> Now that xen_pt_update_entry() is able to deal with different mapping size, we can replace the open-coding of the page-tables update by a call to modify_xen_mappings(). As the function is not meant to fail, a BUG_ON() is added to check the return. Signed-off-by: Julien Grall <julien.grall@xxxxxxx> Signed-off-by: Julien Grall <jgrall@xxxxxxxxxx> --- Changes in v2: - Stay consistent with how function name are used in the commit message - Add my AWS signed-off-by --- xen/arch/arm/mm.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c index 7b4b9de8693e..f088a4b2de96 100644 --- a/xen/arch/arm/mm.c +++ b/xen/arch/arm/mm.c @@ -599,11 +599,11 @@ void * __init early_fdt_map(paddr_t fdt_paddr) void __init remove_early_mappings(void) { - lpae_t pte = {0}; - write_pte(xen_second + second_table_offset(BOOT_FDT_VIRT_START), pte); - write_pte(xen_second + second_table_offset(BOOT_FDT_VIRT_START + SZ_2M), - pte); - flush_xen_tlb_range_va(BOOT_FDT_VIRT_START, BOOT_FDT_SLOT_SIZE); + int rc; + + rc = modify_xen_mappings(BOOT_FDT_VIRT_START, BOOT_FDT_VIRT_END, + _PAGE_BLOCK); + BUG_ON(rc); } /* -- 2.32.0
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |