[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [PATCH v3 19/52] xen/arm: switch to use ioremap_xxx in common file
In arm, with the introduction of MPU system, VMAP scheme, taking advantage of virtual translation, will become a MMU-only feature. So we want to avoid using direct access to all vmap-related functions, like __vmap(), in common files, and switch to use more generic eoremap_xxx instead. Then later, we also just need to implement MPU version of ioremap_xxx. Signed-off-by: Penny Zheng <penny.zheng@xxxxxxx> Signed-off-by: Wei Chen <wei.chen@xxxxxxx> --- v3: - new commit --- xen/arch/arm/kernel.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/xen/arch/arm/kernel.c b/xen/arch/arm/kernel.c index d13ef0330b..30f8bc5923 100644 --- a/xen/arch/arm/kernel.c +++ b/xen/arch/arm/kernel.c @@ -172,7 +172,6 @@ static __init int kernel_decompress(struct bootmodule *mod, uint32_t offset) unsigned int kernel_order_out; paddr_t output_size; struct page_info *pages; - mfn_t mfn; int i; paddr_t addr = mod->start; paddr_t size = mod->size; @@ -209,13 +208,18 @@ static __init int kernel_decompress(struct bootmodule *mod, uint32_t offset) iounmap(input); return -ENOMEM; } - mfn = page_to_mfn(pages); - output = __vmap(&mfn, 1 << kernel_order_out, 1, 1, PAGE_HYPERVISOR, VMAP_DEFAULT); + output = ioremap_cache(page_to_maddr(pages), + pfn_to_paddr(1UL << kernel_order_out)); + if ( output == NULL ) + { + iounmap(output); + return -EFAULT; + } rc = perform_gunzip(output, input, size); clean_dcache_va_range(output, output_size); iounmap(input); - vunmap(output); + iounmap(output); if ( rc ) { -- 2.25.1
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |