lkml.org 
[lkml]   [2015]   [Sep]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] ARM:mm: define arch-specific IOREMAP_MAX_ORDER only in !SMP && !LPAE case
The arch-specific IOREMAP_MAX_ORDER is introduced in
commit: ff0daca([ARM] Add section support to ioremap) and
commit: a069c89 ([ARM] 3705/1: add supersection support to ioremap()).
But supersections and sections mappings are only used in !SMP && !LPAE case.
Otherwise, mapping is created using the usual 4K pages.

In most cases without !SMP && !LPAE, the big alignment cause high fragmentation
issue in vmalloc area.
Here we use arch-specific IOREMAP_MAX_ORDER only in !SMP && !LPAE case,
otherwise use generic IOREMAP_MAX_ORDER in include/linux/vmalloc.h.

Signed-off-by: Zhang Zhen <zhenzhang.zhang@huawei.com>
---
arch/arm/include/asm/memory.h | 2 ++
1 file changed, 2 insertions(+)

diff --git a/arch/arm/include/asm/memory.h b/arch/arm/include/asm/memory.h
index b7f6fb4..3209012 100644
--- a/arch/arm/include/asm/memory.h
+++ b/arch/arm/include/asm/memory.h
@@ -76,10 +76,12 @@
*/
#define XIP_VIRT_ADDR(physaddr) (MODULES_VADDR + ((physaddr) & 0x000fffff))

+#if !defined(CONFIG_SMP) && !defined(CONFIG_ARM_LPAE)
/*
* Allow 16MB-aligned ioremap pages
*/
#define IOREMAP_MAX_ORDER 24
+#endif

#else /* CONFIG_MMU */

--
1.9.1

.






\
 
 \ /
  Last update: 2015-09-08 05:01    [W:0.070 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site