From a550b3f35a32e6c74c78aeda1154b1d901574168 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Wed, 23 Nov 2016 07:47:57 +0100 Subject: score: Force Per_CPU_Control::executing alignment This fixes the CPU ports with relaxed alignment restrictions, e.g. type alignment is less than the type size. Close #2822. Close #2823. --- cpukit/score/include/rtems/score/percpu.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cpukit/score/include/rtems/score/percpu.h b/cpukit/score/include/rtems/score/percpu.h index 78196e8a2d..3b63c7c1e1 100644 --- a/cpukit/score/include/rtems/score/percpu.h +++ b/cpukit/score/include/rtems/score/percpu.h @@ -334,6 +334,13 @@ typedef struct Per_CPU_Control { */ volatile bool dispatch_necessary; + /* + * Ensure that the executing member is at least 4-byte aligned, see + * PER_CPU_OFFSET_EXECUTING. This is necessary on CPU ports with relaxed + * alignment restrictions, e.g. type alignment is less than the type size. + */ + bool reserved_for_executing_alignment[ 3 ]; + /** * @brief This is the thread executing on this processor. * -- cgit v1.2.3