[rtems commit] arm: Make barrier operations more visible

Sebastian Huber sebh at rtems.org
Thu Aug 22 12:16:33 UTC 2013


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

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Thu Aug 22 13:19:06 2013 +0200

arm: Make barrier operations more visible

---

 cpukit/score/cpu/arm/rtems/score/cpu.h |   25 +++++++++++++++----------
 1 files changed, 15 insertions(+), 10 deletions(-)

diff --git a/cpukit/score/cpu/arm/rtems/score/cpu.h b/cpukit/score/cpu/arm/rtems/score/cpu.h
index a11de9a..205e41f 100644
--- a/cpukit/score/cpu/arm/rtems/score/cpu.h
+++ b/cpukit/score/cpu/arm/rtems/score/cpu.h
@@ -285,6 +285,21 @@ typedef struct {
 
 extern uint32_t arm_cpu_mode;
 
+static inline void _ARM_Data_memory_barrier( void )
+{
+  __asm__ volatile ( "dmb" : : : "memory" );
+}
+
+static inline void _ARM_Data_synchronization_barrier( void )
+{
+  __asm__ volatile ( "dsb" : : : "memory" );
+}
+
+static inline void _ARM_Instruction_synchronization_barrier( void )
+{
+  __asm__ volatile ( "isb" : : : "memory" );
+}
+
 static inline uint32_t arm_interrupt_disable( void )
 {
   uint32_t level;
@@ -465,16 +480,6 @@ void _CPU_Context_validate( uintptr_t pattern );
 
   void _CPU_SMP_Send_interrupt( uint32_t target_processor_index );
 
-  static inline void _ARM_Data_memory_barrier( void )
-  {
-    __asm__ volatile ( "dmb" : : : "memory" );
-  }
-
-  static inline void _ARM_Data_synchronization_barrier( void )
-  {
-    __asm__ volatile ( "dsb" : : : "memory" );
-  }
-
   static inline void _ARM_Send_event( void )
   {
     __asm__ volatile ( "sev" : : : "memory" );




More information about the vc mailing list