18 #ifndef _RTEMS_SCORE_SMPIMPL_H 19 #define _RTEMS_SCORE_SMPIMPL_H 45 #define SMP_MESSAGE_SHUTDOWN 0x1UL 52 #define SMP_MESSAGE_TEST 0x2UL 59 #define SMP_MESSAGE_MULTICAST_ACTION 0x4UL 65 SMP_FATAL_BOOT_PROCESSOR_NOT_ASSIGNED_TO_SCHEDULER,
66 SMP_FATAL_MANDATORY_PROCESSOR_NOT_PRESENT,
67 SMP_FATAL_MULTITASKING_START_ON_INVALID_PROCESSOR,
68 SMP_FATAL_MULTITASKING_START_ON_UNASSIGNED_PROCESSOR,
70 SMP_FATAL_SHUTDOWN_RESPONSE,
71 SMP_FATAL_START_OF_MANDATORY_PROCESSOR_FAILED
74 static inline void _SMP_Fatal( SMP_Fatal_code
code )
84 #if defined( RTEMS_SMP ) 87 #define _SMP_Handler_initialize() \ 91 #if defined( RTEMS_SMP ) 117 void _SMP_Start_multitasking_on_secondary_processor(
void )
120 typedef void ( *SMP_Test_message_handler )(
Per_CPU_Control *cpu_self );
122 extern SMP_Test_message_handler _SMP_Test_message_handler;
130 static inline void _SMP_Set_test_message_handler(
131 SMP_Test_message_handler handler
134 _SMP_Test_message_handler = handler;
140 void _SMP_Multicast_actions_process(
void );
145 static inline void _SMP_Inter_processor_interrupt_handler(
void )
149 if ( _Atomic_Load_ulong( &cpu_self->message, ATOMIC_ORDER_RELAXED ) != 0 ) {
150 unsigned long message = _Atomic_Exchange_ulong(
157 _SMP_Fatal( SMP_FATAL_SHUTDOWN_RESPONSE );
162 ( *_SMP_Test_message_handler )( cpu_self );
166 _SMP_Multicast_actions_process();
180 bool _SMP_Should_start_processor( uint32_t cpu_index );
190 void _SMP_Send_message( uint32_t cpu_index,
unsigned long message );
202 void _SMP_Send_message_broadcast(
203 unsigned long message
215 void _SMP_Send_message_multicast(
216 const size_t setsize,
217 const cpu_set_t *cpus,
218 unsigned long message
221 typedef void ( *SMP_Multicast_action_handler )(
void *arg );
233 void _SMP_Multicast_action(
234 const size_t setsize,
235 const cpu_set_t *cpus,
236 SMP_Multicast_action_handler handler,
246 #if defined( RTEMS_SMP ) 249 #define _SMP_Request_start_multitasking() \ 260 #if defined( RTEMS_SMP ) 263 #define _SMP_Request_shutdown() \ Definition: media-server.c:33
Fatal source of SMP domain.
Definition: interr.h:124
void _Terminate(Internal_errors_Source the_source, bool is_internal, Internal_errors_t the_error)
Initiates system termination.
Definition: interr.c:31
#define SMP_MESSAGE_SHUTDOWN
SMP message to request a processor shutdown.
Definition: smpimpl.h:45
SuperCore SMP Support API.
#define _SMP_Handler_initialize()
Initialize SMP Handler.
Definition: smpimpl.h:87
This include file defines the per CPU information required by RTEMS.
Per CPU Core Structure.
Definition: percpu.h:233
#define SMP_MESSAGE_MULTICAST_ACTION
SMP message to request a multicast action.
Definition: smpimpl.h:59
#define _SMP_Request_shutdown()
Requests a shutdown of all processors.
Definition: smpimpl.h:263
Definition: inftrees.h:25
SMP_Fatal_code
SMP fatal codes.
Definition: smpimpl.h:64
#define RTEMS_COMPILER_NO_RETURN_ATTRIBUTE
The following macro is a compiler specific way to indicate that the method will NOT return to the cal...
Definition: basedefs.h:162
#define SMP_MESSAGE_TEST
SMP message to request a test handler invocation.
Definition: smpimpl.h:52
#define _SMP_Request_start_multitasking()
Requests a multitasking start on all configured and available processors.
Definition: smpimpl.h:249