[rtems commit] sparc: Add static assertion

Sebastian Huber sebh at rtems.org
Tue May 26 12:14:06 UTC 2015


Module:    rtems
Branch:    master
Commit:    76030c703bdfb2ad7bcfb213b99f306d69217af0
Changeset: http://git.rtems.org/rtems/commit/?id=76030c703bdfb2ad7bcfb213b99f306d69217af0

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Tue May 26 14:13:44 2015 +0200

sparc: Add static assertion

---

 cpukit/score/cpu/sparc/cpu.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/cpukit/score/cpu/sparc/cpu.c b/cpukit/score/cpu/sparc/cpu.c
index 2560f26..f96d1ea 100644
--- a/cpukit/score/cpu/sparc/cpu.c
+++ b/cpukit/score/cpu/sparc/cpu.c
@@ -97,6 +97,11 @@ SPARC_ASSERT_ISF_OFFSET(i7, I7);
 SPARC_ASSERT_ISF_OFFSET(y, Y);
 SPARC_ASSERT_ISF_OFFSET(tpc, TPC);
 
+RTEMS_STATIC_ASSERT(
+  sizeof(CPU_Interrupt_frame) == CONTEXT_CONTROL_INTERRUPT_FRAME_SIZE,
+  CPU_Interrupt_frame_size
+);
+
 /* https://devel.rtems.org/ticket/2352 */
 RTEMS_STATIC_ASSERT(
   sizeof(CPU_Interrupt_frame) % CPU_ALIGNMENT == 0,



More information about the vc mailing list