summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-10-16 08:15:03 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-10-26 09:13:19 +0100
commit143696acbdd8740eaa8114c7c307ef4834134454 (patch)
tree1e520c91984f3b806ff00608568a0e2a7113b278 /cpukit/score/include/rtems
parentbasedefs.h: Add compiler attributes (diff)
downloadrtems-143696acbdd8740eaa8114c7c307ef4834134454.tar.bz2
basedefs.h: Add and use RTEMS_NO_RETURN
Diffstat (limited to 'cpukit/score/include/rtems')
-rw-r--r--cpukit/score/include/rtems/score/assert.h2
-rw-r--r--cpukit/score/include/rtems/score/basedefs.h10
-rw-r--r--cpukit/score/include/rtems/score/interr.h2
-rw-r--r--cpukit/score/include/rtems/score/smpimpl.h2
-rw-r--r--cpukit/score/include/rtems/score/threadimpl.h2
5 files changed, 10 insertions, 8 deletions
diff --git a/cpukit/score/include/rtems/score/assert.h b/cpukit/score/include/rtems/score/assert.h
index 63083784fa..d4253f87da 100644
--- a/cpukit/score/include/rtems/score/assert.h
+++ b/cpukit/score/include/rtems/score/assert.h
@@ -61,7 +61,7 @@ extern "C" {
/* normal build is newlib. */
void __assert_func(const char *, int, const char *, const char *)
- RTEMS_COMPILER_NO_RETURN_ATTRIBUTE;
+ RTEMS_NO_RETURN;
#define _Assert( _e ) \
( ( _e ) ? \
diff --git a/cpukit/score/include/rtems/score/basedefs.h b/cpukit/score/include/rtems/score/basedefs.h
index 8e145f58e6..5575a068c7 100644
--- a/cpukit/score/include/rtems/score/basedefs.h
+++ b/cpukit/score/include/rtems/score/basedefs.h
@@ -154,14 +154,16 @@
* rtems_fatal_error_occurred and _Terminate.
*/
#if defined(RTEMS_SCHEDSIM)
- #define RTEMS_COMPILER_NO_RETURN_ATTRIBUTE
+ #define RTEMS_NO_RETURN
#elif defined(__GNUC__)
- #define RTEMS_COMPILER_NO_RETURN_ATTRIBUTE \
- __attribute__ ((noreturn))
+ #define RTEMS_NO_RETURN __attribute__((__noreturn__))
#else
- #define RTEMS_COMPILER_NO_RETURN_ATTRIBUTE
+ #define RTEMS_NO_RETURN
#endif
+/* Provided for backward compatibility */
+#define RTEMS_COMPILER_NO_RETURN_ATTRIBUTE RTEMS_NO_RETURN
+
/**
* The following defines a compiler specific attribute which informs
* the compiler that the method has no effect except the return value
diff --git a/cpukit/score/include/rtems/score/interr.h b/cpukit/score/include/rtems/score/interr.h
index 988a00dd44..f09d6e90a5 100644
--- a/cpukit/score/include/rtems/score/interr.h
+++ b/cpukit/score/include/rtems/score/interr.h
@@ -228,7 +228,7 @@ void _Terminate(
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
-) RTEMS_COMPILER_NO_RETURN_ATTRIBUTE;
+) RTEMS_NO_RETURN;
#ifdef __cplusplus
}
diff --git a/cpukit/score/include/rtems/score/smpimpl.h b/cpukit/score/include/rtems/score/smpimpl.h
index 3167e82a82..09c47ecf16 100644
--- a/cpukit/score/include/rtems/score/smpimpl.h
+++ b/cpukit/score/include/rtems/score/smpimpl.h
@@ -115,7 +115,7 @@ static inline void _SMP_Fatal( SMP_Fatal_code code )
* This function does not return to the caller.
*/
void _SMP_Start_multitasking_on_secondary_processor( void )
- RTEMS_COMPILER_NO_RETURN_ATTRIBUTE;
+ RTEMS_NO_RETURN;
typedef void ( *SMP_Test_message_handler )( Per_CPU_Control *cpu_self );
diff --git a/cpukit/score/include/rtems/score/threadimpl.h b/cpukit/score/include/rtems/score/threadimpl.h
index 7412bd9633..906bdb1862 100644
--- a/cpukit/score/include/rtems/score/threadimpl.h
+++ b/cpukit/score/include/rtems/score/threadimpl.h
@@ -132,7 +132,7 @@ void _Thread_Create_idle(void);
* part of initialization and its invocation is the last act of
* the non-multitasking part of the system initialization.
*/
-void _Thread_Start_multitasking( void ) RTEMS_COMPILER_NO_RETURN_ATTRIBUTE;
+void _Thread_Start_multitasking( void ) RTEMS_NO_RETURN;
/**
* @brief Allocate the requested stack space for the thread.