summaryrefslogtreecommitdiffstats
path: root/bsps/aarch64/include/bsp/aarch64-mmu.h
diff options
context:
space:
mode:
authorKinsey Moore <kinsey.moore@oarcorp.com>2022-07-05 13:35:28 -0500
committerJoel Sherrill <joel@rtems.org>2022-07-06 10:22:08 -0500
commit2f6ee01e9ebd2776d36e12bf93c11cefd4274a8e (patch)
treececbdccc485e0e55b117fc9cd345ea3f29c37820 /bsps/aarch64/include/bsp/aarch64-mmu.h
parentcpukit/aarch64: Remove _CPU_ISR_install_vector (diff)
downloadrtems-2f6ee01e9ebd2776d36e12bf93c11cefd4274a8e.tar.bz2
bsps/aarch64: Use MMU pages appropriately
There were two bugs with MMU page use that were partially hiding each other. The linker script page table section was 4x the size it needed to be and the page table allocation routine was allocating pages PTRSIZE times larger than it needed to. On ILP32, this resulted in incorrect but functional allocation. On LP64, this resulted in allocation failures earlier than expected.
Diffstat (limited to 'bsps/aarch64/include/bsp/aarch64-mmu.h')
-rw-r--r--bsps/aarch64/include/bsp/aarch64-mmu.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/bsps/aarch64/include/bsp/aarch64-mmu.h b/bsps/aarch64/include/bsp/aarch64-mmu.h
index 6e589cd6cd..bca7e0ce8d 100644
--- a/bsps/aarch64/include/bsp/aarch64-mmu.h
+++ b/bsps/aarch64/include/bsp/aarch64-mmu.h
@@ -145,8 +145,8 @@ BSP_START_TEXT_SECTION static inline rtems_status_code
aarch64_mmu_page_table_alloc( uint64_t **page_table )
{
/* First page table is already in use as TTB0 */
- static uintptr_t *current_page_table =
- (uintptr_t *) bsp_translation_table_base;
+ static uintptr_t current_page_table =
+ (uintptr_t) bsp_translation_table_base;
current_page_table += MMU_PAGE_SIZE;
*page_table = (uint64_t *) current_page_table;