summaryrefslogtreecommitdiff
path: root/include/bl31
diff options
context:
space:
mode:
authorSoby Mathew <soby.mathew@arm.com>2014-08-14 11:33:56 +0100
committerDan Handley <dan.handley@arm.com>2014-08-20 19:13:25 +0100
commit9b4768417051ead50135d1d7675cab940d864e8d (patch)
tree3105204d317eb7516d184923a8ea66da3aa767f2 /include/bl31
parentaecc0840805672279e4165f4d368a59b5c20771e (diff)
Introduce framework for CPU specific operations
This patch introduces a framework which will allow CPUs to perform implementation defined actions after a CPU reset, during a CPU or cluster power down, and when a crash occurs. CPU specific reset handlers have been implemented in this patch. Other handlers will be implemented in subsequent patches. Also moved cpu_helpers.S to the new directory lib/cpus/aarch64/. Change-Id: I1ca1bade4d101d11a898fb30fea2669f9b37b956
Diffstat (limited to 'include/bl31')
-rw-r--r--include/bl31/cpu_data.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/include/bl31/cpu_data.h b/include/bl31/cpu_data.h
index 355160b9..ba7ae063 100644
--- a/include/bl31/cpu_data.h
+++ b/include/bl31/cpu_data.h
@@ -32,14 +32,16 @@
#define __CPU_DATA_H__
/* Offsets for the cpu_data structure */
-#define CPU_DATA_CRASH_BUF_OFFSET 0x10
+#define CPU_DATA_CRASH_BUF_OFFSET 0x20
#if CRASH_REPORTING
#define CPU_DATA_LOG2SIZE 7
#else
#define CPU_DATA_LOG2SIZE 6
#endif
/* need enough space in crash buffer to save 8 registers */
-#define CPU_DATA_CRASH_BUF_SIZE 64
+#define CPU_DATA_CRASH_BUF_SIZE 64
+#define CPU_DATA_CPU_OPS_PTR 0x10
+
#ifndef __ASSEMBLY__
#include <arch_helpers.h>
@@ -66,10 +68,11 @@
******************************************************************************/
typedef struct cpu_data {
void *cpu_context[2];
+ uint64_t cpu_ops_ptr;
+ struct psci_cpu_data psci_svc_cpu_data;
#if CRASH_REPORTING
uint64_t crash_buf[CPU_DATA_CRASH_BUF_SIZE >> 3];
#endif
- struct psci_cpu_data psci_svc_cpu_data;
} __aligned(CACHE_WRITEBACK_GRANULE) cpu_data_t;
#if CRASH_REPORTING
@@ -82,6 +85,10 @@ CASSERT(CPU_DATA_CRASH_BUF_OFFSET == __builtin_offsetof
CASSERT((1 << CPU_DATA_LOG2SIZE) == sizeof(cpu_data_t),
assert_cpu_data_log2size_mismatch);
+CASSERT(CPU_DATA_CPU_OPS_PTR == __builtin_offsetof
+ (cpu_data_t, cpu_ops_ptr),
+ assert_cpu_data_cpu_ops_ptr_offset_mismatch);
+
struct cpu_data *_cpu_data_by_index(uint32_t cpu_index);
struct cpu_data *_cpu_data_by_mpidr(uint64_t mpidr);