aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mm/mmu.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@stericsson.com>2010-07-12 16:50:59 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-07-18 15:29:47 -0400
commitcb9d7707cd9be57830f31616233f6a872ca8416d (patch)
tree6b380a5fc3c0f8efcc97455ee85a08da1d6ce4f9 /arch/arm/mm/mmu.c
parentf159f4ed55bb0fa5470800641e03a13a7e0eae6e (diff)
ARM: 6222/1: add memory types for the TCMs
The earlier TCM memory regions were mapped as MT_MEMORY_UNCACHED which doesn't really work on platforms supporting the new v6 features like the NX bit. Add unique MT_MEMORY_[I|D]TCM types instead. Cc: Nicolas Pitre <nico@fluxnic.net> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mm/mmu.c')
-rw-r--r--arch/arm/mm/mmu.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/arm/mm/mmu.c b/arch/arm/mm/mmu.c
index 285894171186..e53480148c05 100644
--- a/arch/arm/mm/mmu.c
+++ b/arch/arm/mm/mmu.c
@@ -258,6 +258,19 @@ static struct mem_type mem_types[] = {
258 .prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE, 258 .prot_sect = PMD_TYPE_SECT | PMD_SECT_AP_WRITE,
259 .domain = DOMAIN_KERNEL, 259 .domain = DOMAIN_KERNEL,
260 }, 260 },
261 [MT_MEMORY_DTCM] = {
262 .prot_pte = L_PTE_PRESENT | L_PTE_YOUNG |
263 L_PTE_DIRTY | L_PTE_WRITE,
264 .prot_l1 = PMD_TYPE_TABLE,
265 .prot_sect = PMD_TYPE_SECT | PMD_SECT_XN,
266 .domain = DOMAIN_KERNEL,
267 },
268 [MT_MEMORY_ITCM] = {
269 .prot_pte = L_PTE_PRESENT | L_PTE_YOUNG | L_PTE_DIRTY |
270 L_PTE_USER | L_PTE_EXEC,
271 .prot_l1 = PMD_TYPE_TABLE,
272 .domain = DOMAIN_IO,
273 },
261}; 274};
262 275
263const struct mem_type *get_mem_type(unsigned int type) 276const struct mem_type *get_mem_type(unsigned int type)