diff options
Diffstat (limited to 'cpukit')
-rw-r--r-- | cpukit/rtems/Makefile.am | 2 | ||||
-rw-r--r-- | cpukit/rtems/include/rtems/rtems/modes.h | 21 | ||||
-rw-r--r-- | cpukit/rtems/src/modes.c (renamed from cpukit/rtems/src/attr.c) | 18 |
3 files changed, 33 insertions, 8 deletions
diff --git a/cpukit/rtems/Makefile.am b/cpukit/rtems/Makefile.am index 6dc67e03a1..e9f990626e 100644 --- a/cpukit/rtems/Makefile.am +++ b/cpukit/rtems/Makefile.am @@ -255,7 +255,7 @@ librtems_a_SOURCES += src/dpmemdata.c ## WORKSPACE_FILES librtems_a_SOURCES += src/workspace.c -librtems_a_SOURCES += src/attr.c +librtems_a_SOURCES += src/modes.c librtems_a_SOURCES += src/status.c diff --git a/cpukit/rtems/include/rtems/rtems/modes.h b/cpukit/rtems/include/rtems/rtems/modes.h index 0665d17c8b..c24b072acf 100644 --- a/cpukit/rtems/include/rtems/rtems/modes.h +++ b/cpukit/rtems/include/rtems/rtems/modes.h @@ -96,6 +96,27 @@ typedef uint32_t Modes_Control; #define RTEMS_INTERRUPT_LEVEL( _mode_set ) \ ( (_mode_set) & RTEMS_INTERRUPT_MASK ) +/** + * @brief Interrupt Mask Variable + * + * This variable is used by bindings from languages other than C and C++. + */ +extern const uint32_t rtems_interrupt_mask; + +/** + * @brief Body for RTEMS_INTERRUPT_LEVEL macro. + * + * @param[in] level is the desired interrupt level + * + * @return This methods returns a mode with the desired interrupt + * @a level in the proper bitfield location. + * + * @note This variable is used by bindings from languages other than + * C and C++. + */ +Modes_Control rtems_interrupt_level_body( + uint32_t level +); #ifndef __RTEMS_APPLICATION__ #include <rtems/rtems/modes.inl> diff --git a/cpukit/rtems/src/attr.c b/cpukit/rtems/src/modes.c index 2312d36bb5..0c51281177 100644 --- a/cpukit/rtems/src/attr.c +++ b/cpukit/rtems/src/modes.c @@ -1,15 +1,19 @@ -/* - * Body for Attribute Routines +/** + * @file * + * @body Body for Mode Routines Implemented as Macros * - * COPYRIGHT (c) 1989-1999. + * This file contains bodies for Mode Macros which are + * needed by language bindings other than C and C++. + */ + +/* + * COPYRIGHT (c) 1989-2012. * On-Line Applications Research Corporation (OAR). * * The license and distribution terms for this file may be * found in the file LICENSE in this distribution or at * http://www.rtems.com/license/LICENSE. - * - * $Id$ */ #if HAVE_CONFIG_H @@ -21,9 +25,9 @@ #include <rtems/score/stack.h> #include <rtems/rtems/modes.h> -uint32_t rtems_interrupt_mask = RTEMS_INTERRUPT_MASK; +const uint32_t rtems_interrupt_mask = RTEMS_INTERRUPT_MASK; -rtems_attribute rtems_interrupt_level_attribute( +Modes_Control rtems_interrupt_level_body( uint32_t level ) { |