summaryrefslogtreecommitdiff
path: root/bl31/aarch64
diff options
context:
space:
mode:
Diffstat (limited to 'bl31/aarch64')
-rw-r--r--bl31/aarch64/bl31_arch_setup.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/bl31/aarch64/bl31_arch_setup.c b/bl31/aarch64/bl31_arch_setup.c
index faca2a1..793b895 100644
--- a/bl31/aarch64/bl31_arch_setup.c
+++ b/bl31/aarch64/bl31_arch_setup.c
@@ -40,7 +40,7 @@
void bl31_arch_setup(void)
{
unsigned long tmp_reg = 0;
- unsigned int counter_base_frequency;
+ uint64_t counter_freq;
/* Enable alignment checks and set the exception endianness to LE */
tmp_reg = read_sctlr_el3();
@@ -62,14 +62,9 @@ void bl31_arch_setup(void)
enable_serror();
enable_debug_exceptions();
- /* Read the frequency from Frequency modes table */
- counter_base_frequency = mmio_read_32(SYS_CNTCTL_BASE + CNTFID_OFF);
- /* The first entry of the frequency modes table must not be 0 */
- assert(counter_base_frequency != 0);
-
/* Program the counter frequency */
- write_cntfrq_el0(counter_base_frequency);
- return;
+ counter_freq = plat_get_syscnt_freq();
+ write_cntfrq_el0(counter_freq);
}
/*******************************************************************************