summaryrefslogtreecommitdiffstats
path: root/bsps
diff options
context:
space:
mode:
authorKinsey Moore <kinsey.moore@oarcorp.com>2021-10-25 12:19:13 -0500
committerJoel Sherrill <joel@rtems.org>2021-11-01 08:39:00 -0500
commita857a225d06b9090b0386934551392af073c731e (patch)
treecbfdc97aa7cdbd0db35673e47972ee79d6af2bea /bsps
parentbsps/aarch64: Mask debug events from startup (diff)
downloadrtems-a857a225d06b9090b0386934551392af073c731e.tar.bz2
cpukit/aarch64: Add libdebugger support
This adds support for libdebugger under AArch64 using software breakpoints and the single-step execution mode present in all AArch64 CPUs.
Diffstat (limited to 'bsps')
-rw-r--r--bsps/aarch64/include/bsp/aarch64-mmu.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/bsps/aarch64/include/bsp/aarch64-mmu.h b/bsps/aarch64/include/bsp/aarch64-mmu.h
index 9926eb97f6..b1a471d534 100644
--- a/bsps/aarch64/include/bsp/aarch64-mmu.h
+++ b/bsps/aarch64/include/bsp/aarch64-mmu.h
@@ -371,6 +371,17 @@ aarch64_mmu_enable( void )
_AArch64_Write_sctlr_el1( sctlr );
}
+BSP_START_TEXT_SECTION static inline void
+aarch64_mmu_disable( void )
+{
+ uint64_t sctlr;
+
+ /* Enable MMU and cache */
+ sctlr = _AArch64_Read_sctlr_el1();
+ sctlr &= ~(AARCH64_SCTLR_EL1_M);
+ _AArch64_Write_sctlr_el1( sctlr );
+}
+
BSP_START_TEXT_SECTION static inline void aarch64_mmu_setup( void )
{
/* Set TCR */