diff options
Diffstat (limited to 'cpukit/score/cpu/no_cpu')
-rw-r--r-- | cpukit/score/cpu/no_cpu/rtems/score/cpuimpl.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/cpukit/score/cpu/no_cpu/rtems/score/cpuimpl.h b/cpukit/score/cpu/no_cpu/rtems/score/cpuimpl.h index 6b8b601cb0..457ce4c8bb 100644 --- a/cpukit/score/cpu/no_cpu/rtems/score/cpuimpl.h +++ b/cpukit/score/cpu/no_cpu/rtems/score/cpuimpl.h @@ -5,6 +5,8 @@ */ /* + * Copyright (c) 2016 embedded brains GmbH. + * * The license and distribution terms for this file may be * found in the file LICENSE in this distribution or at * http://www.rtems.org/license/LICENSE. @@ -21,6 +23,16 @@ extern "C" { #endif +/** + * @brief Optional method to get the executing thread. + * + * This is optional. Not every CPU port needs this. It is only an optional + * optimization variant. In case this macro is undefined, the default + * implementation uses the per-CPU information and the current processor index + * to get the executing thread. + */ +#define _CPU_Get_thread_executing() ( _CPU_Per_CPU_current->executing ) + #ifdef __cplusplus } #endif |