diff options
author | Vikram Kanigiri <vikram.kanigiri@arm.com> | 2015-01-29 18:27:38 +0000 |
---|---|---|
committer | Vikram Kanigiri <vikram.kanigiri@arm.com> | 2015-03-13 10:38:09 +0000 |
commit | 12e7c4ab0bbc9d9d4e950bdbda5a86f61c13bc1a (patch) | |
tree | b8a888b28f2df72aaae1b759fa3c3c74c8693a2a /bl31 | |
parent | 5930eadbe5d8d4c3f15fd910476f72cd5bf86f44 (diff) |
Initialise cpu ops after enabling data cache
The cpu-ops pointer was initialized before enabling the data cache in the cold
and warm boot paths. This required a DCIVAC cache maintenance operation to
invalidate any stale cache lines resident in other cpus.
This patch moves this initialization to the bl31_arch_setup() function
which is always called after the data cache and MMU has been enabled.
This change removes the need:
1. for the DCIVAC cache maintenance operation.
2. to initialise the CPU ops upon resumption from a PSCI CPU_SUSPEND
call since memory contents are always preserved in this case.
Change-Id: Ibb2fa2f7460d1a1f1e721242025e382734c204c6
Diffstat (limited to 'bl31')
-rw-r--r-- | bl31/aarch64/bl31_arch_setup.c | 4 | ||||
-rw-r--r-- | bl31/aarch64/bl31_entrypoint.S | 6 |
2 files changed, 4 insertions, 6 deletions
diff --git a/bl31/aarch64/bl31_arch_setup.c b/bl31/aarch64/bl31_arch_setup.c index a88b029e..edf10188 100644 --- a/bl31/aarch64/bl31_arch_setup.c +++ b/bl31/aarch64/bl31_arch_setup.c @@ -33,6 +33,7 @@ #include <assert.h> #include <bl_common.h> #include <bl31.h> +#include <cpu_data.h> #include <platform.h> /******************************************************************************* @@ -47,4 +48,7 @@ void bl31_arch_setup(void) /* Program the counter frequency */ write_cntfrq_el0(plat_get_syscnt_freq()); + + /* Initialize the cpu_ops pointer. */ + init_cpu_ops(); } diff --git a/bl31/aarch64/bl31_entrypoint.S b/bl31/aarch64/bl31_entrypoint.S index 01d7a7f5..186b1cbc 100644 --- a/bl31/aarch64/bl31_entrypoint.S +++ b/bl31/aarch64/bl31_entrypoint.S @@ -162,12 +162,6 @@ func bl31_entrypoint #endif /* --------------------------------------------- - * Initialize the cpu_ops pointer. - * --------------------------------------------- - */ - bl init_cpu_ops - - /* --------------------------------------------- * Use SP_EL0 for the C runtime stack. * --------------------------------------------- */ |