summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@arm.com>2011-05-06 16:27:13 +0100
committerCatalin Marinas <catalin.marinas@arm.com>2011-05-06 16:28:05 +0100
commite4682d17a2b3b2171dd87b594da534bc1b097b01 (patch)
tree962ba70d1d74ed25df04161138d98f63eb67dd3a
parentd1cf723140258fe2178fd0775d872731a4e3d40c (diff)
Set the generic timer frequency (normally done by the firmware).
-rw-r--r--boot.S12
1 files changed, 12 insertions, 0 deletions
diff --git a/boot.S b/boot.S
index 867290b..433c428 100644
--- a/boot.S
+++ b/boot.S
@@ -13,6 +13,18 @@
.globl _start
_start:
#ifdef SMP
+#ifdef VEXPRESS
+ @
+ @ Program architected timer frequency
+ @
+ mrc p15, 0, r0, c0, c1, 1 @ CPUID_EXT_PFR1
+ lsr r0, r0, #16
+ and r0, r0, #1 @ Check generic timer support
+ beq 1f
+ ldr r0, =24000000 @ 24MHz timer frequency
+ mcr p15, 0, r0, c14, c0, 0 @ CNTFRQ
+1:
+#endif
@
@ CPU initialisation
@