summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHeyi Guo <heyi.guo@linaro.org>2015-05-13 18:21:58 +0000
committeroliviermartin <oliviermartin@Edk2>2015-05-13 18:21:58 +0000
commitc37e542ba01bfe3cb3932cfdced86d4517e21950 (patch)
treee058831115fd7301ca519d5004e77b79a4a29075
parentb51cffe12fbea45a1112bffea40a63efc7e79982 (diff)
downloadedk2-c37e542ba01bfe3cb3932cfdced86d4517e21950.tar.gz
edk2-c37e542ba01bfe3cb3932cfdced86d4517e21950.tar.bz2
edk2-c37e542ba01bfe3cb3932cfdced86d4517e21950.zip
ArmPkg: fix ArmWriteCntkCtl simple code bug
We need to use msr instruction to write system register. It seems the code was simply copied from ArmReadCntkCtl. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Heyi Guo <heyi.guo@linaro.org> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@17440 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--ArmPkg/Library/ArmLib/AArch64/AArch64ArchTimerSupport.S2
1 files changed, 1 insertions, 1 deletions
diff --git a/ArmPkg/Library/ArmLib/AArch64/AArch64ArchTimerSupport.S b/ArmPkg/Library/ArmLib/AArch64/AArch64ArchTimerSupport.S
index 1ac01086aa..3944d8bcb4 100644
--- a/ArmPkg/Library/ArmLib/AArch64/AArch64ArchTimerSupport.S
+++ b/ArmPkg/Library/ArmLib/AArch64/AArch64ArchTimerSupport.S
@@ -58,7 +58,7 @@ ASM_PFX(ArmReadCntkCtl):
ASM_PFX(ArmWriteCntkCtl):
- mrs x0, cntkctl_el1 // Write to CNTK_CTL (Timer PL1 Control Register)
+ msr cntkctl_el1, x0 // Write to CNTK_CTL (Timer PL1 Control Register)
ret