summaryrefslogtreecommitdiffstats
path: root/ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm
diff options
context:
space:
mode:
authorMichael Zimmermann <sigmaepsilon92@gmail.com>2018-01-13 07:52:45 +0100
committerArd Biesheuvel <ard.biesheuvel@linaro.org>2018-01-15 12:02:25 +0000
commit1e1d16971d1ae620d15b685fd76959c94d304319 (patch)
tree8f2cbc006a75facc10fb04d7781111231b5e9b5b /ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm
parent29af38b0f8f2aa7b08f61a9df38a59dbc15e9302 (diff)
downloadedk2-1e1d16971d1ae620d15b685fd76959c94d304319.tar.gz
edk2-1e1d16971d1ae620d15b685fd76959c94d304319.tar.bz2
edk2-1e1d16971d1ae620d15b685fd76959c94d304319.zip
ArmPkg/Library/ArmLib: add ArmWriteSctlr
This currently isn't needed by anything in the edk2 tree but it's useful for externally maintained platforms which have to set this register e.g. to disable alignment aborts. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Michael Zimmermann <sigmaepsilon92@gmail.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Diffstat (limited to 'ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm')
-rw-r--r--ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm3
1 files changed, 3 insertions, 0 deletions
diff --git a/ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm b/ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm
index 85b0feee20..219140c22b 100644
--- a/ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm
+++ b/ArmPkg/Library/ArmLib/Arm/ArmLibSupport.asm
@@ -155,6 +155,9 @@
mrc p15, 0, r0, c1, c0, 0 // Read SCTLR into R0 (Read control register configuration data)
bx lr
+ RVCT_ASM_EXPORT ArmWriteSctlr
+ mcr p15, 0, r0, c1, c0, 0
+ bx lr
RVCT_ASM_EXPORT ArmReadCpuActlr
mrc p15, 0, r0, c1, c0, 1