36 #ifndef _RTEMS_CONFDEFS_THREADS_H 37 #define _RTEMS_CONFDEFS_THREADS_H 39 #ifndef __CONFIGURATION_TEMPLATE_h 40 #error "Do not include this file directly, use <rtems/confdefs.h> instead" 53 #ifdef RTEMS_POSIX_API 54 #include <rtems/posix/threadsup.h> 57 #ifndef CONFIGURE_MAXIMUM_TASKS 58 #define CONFIGURE_MAXIMUM_TASKS 0 61 #define _CONFIGURE_TASKS ( CONFIGURE_MAXIMUM_TASKS + _CONFIGURE_LIBBLOCK_TASKS ) 63 #ifndef CONFIGURE_MINIMUM_TASKS_WITH_USER_PROVIDED_STORAGE 64 #define CONFIGURE_MINIMUM_TASKS_WITH_USER_PROVIDED_STORAGE 0 67 #if CONFIGURE_MINIMUM_TASKS_WITH_USER_PROVIDED_STORAGE > CONFIGURE_MAXIMUM_TASKS 68 #error "CONFIGURE_MINIMUM_TASKS_WITH_USER_PROVIDED_STORAGE shall be less than or equal to CONFIGURE_MAXIMUM_TASKS" 71 #ifndef CONFIGURE_MAXIMUM_POSIX_THREADS 72 #define CONFIGURE_MAXIMUM_POSIX_THREADS 0 75 #if CONFIGURE_MAXIMUM_POSIX_THREADS > 0 76 #include <rtems/posix/pthread.h> 79 #if !defined(CONFIGURE_IDLE_TASK_INITIALIZES_APPLICATION) \ 80 && CONFIGURE_MAXIMUM_TASKS == 0 \ 81 && CONFIGURE_MAXIMUM_POSIX_THREADS == 0 82 #error "You must define one of CONFIGURE_IDLE_TASK_INITIALIZES_APPLICATION, CONFIGURE_MAXIMUM_TASKS, and CONFIGURE_MAXIMUM_POSIX_THREADS" 85 #if !defined(CONFIGURE_RTEMS_INIT_TASKS_TABLE) \ 86 && !defined(CONFIGURE_POSIX_INIT_THREAD_TABLE) \ 87 && !defined(CONFIGURE_IDLE_TASK_INITIALIZES_APPLICATION) 88 #error "You must define one of CONFIGURE_IDLE_TASK_INITIALIZES_APPLICATION, CONFIGURE_RTEMS_INIT_TASKS_TABLE, and CONFIGURE_POSIX_INIT_THREAD_TABLE" 91 #ifndef CONFIGURE_MAXIMUM_THREAD_NAME_SIZE 92 #define CONFIGURE_MAXIMUM_THREAD_NAME_SIZE THREAD_DEFAULT_MAXIMUM_NAME_SIZE 95 #ifndef CONFIGURE_MAXIMUM_THREAD_LOCAL_STORAGE_SIZE 96 #define CONFIGURE_MAXIMUM_THREAD_LOCAL_STORAGE_SIZE 0 105 #ifdef CONFIGURE_SCHEDULER_CBS 106 Scheduler_CBS_Node CBS;
108 #ifdef CONFIGURE_SCHEDULER_EDF 111 #ifdef CONFIGURE_SCHEDULER_EDF_SMP 114 #ifdef CONFIGURE_SCHEDULER_PRIORITY 117 #ifdef CONFIGURE_SCHEDULER_SIMPLE_SMP 120 #ifdef CONFIGURE_SCHEDULER_PRIORITY_SMP 121 Scheduler_priority_SMP_Node Priority_SMP;
123 #ifdef CONFIGURE_SCHEDULER_PRIORITY_AFFINITY_SMP 124 Scheduler_priority_affinity_SMP_Node Priority_affinity_SMP;
126 #ifdef CONFIGURE_SCHEDULER_STRONG_APA 127 Scheduler_strong_APA_Node Strong_APA;
129 #ifdef CONFIGURE_SCHEDULER_USER_PER_THREAD 130 CONFIGURE_SCHEDULER_USER_PER_THREAD User;
132 } Configuration_Scheduler_node;
145 #if CONFIGURE_MAXIMUM_USER_EXTENSIONS > 0 148 Configuration_Scheduler_node Scheduler_nodes[ _CONFIGURE_SCHEDULER_COUNT ];
150 #ifdef RTEMS_POSIX_API 151 POSIX_API_Control API_POSIX;
153 #if CONFIGURE_MAXIMUM_THREAD_NAME_SIZE > 1 156 #ifdef _CONFIGURE_ENABLE_NEWLIB_REENTRANCY 157 struct _reent Newlib;
180 #if CONFIGURE_MAXIMUM_THREAD_NAME_SIZE > 1 184 Control.Join_queue.Queue.name
189 #ifdef RTEMS_POSIX_API 217 #if defined(RTEMS_MULTIPROCESSING) && defined(CONFIGURE_MP_APPLICATION) 218 #define _CONFIGURE_MPCI_RECEIVE_SERVER_COUNT 1 220 #define _CONFIGURE_MPCI_RECEIVE_SERVER_COUNT 0 223 THREAD_INFORMATION_DEFINE(
225 OBJECTS_INTERNAL_API,
226 OBJECTS_INTERNAL_THREADS,
227 _CONFIGURE_MAXIMUM_PROCESSORS + _CONFIGURE_MPCI_RECEIVE_SERVER_COUNT
230 #if _CONFIGURE_TASKS > 0 231 THREAD_INFORMATION_DEFINE(
239 #if CONFIGURE_MAXIMUM_POSIX_THREADS > 0 240 const size_t _POSIX_Threads_Minimum_stack_size =
243 THREAD_INFORMATION_DEFINE(
246 OBJECTS_POSIX_THREADS,
#define CONFIGURE_MAXIMUM_USER_EXTENSIONS
This configuration option is an integer define.
Scheduler node specialization for EDF schedulers.
Evaluate Per-CPU Configuration Options.
Evaluate Unlimited Objects Configuration Options.
Evaluate Scheduler Configuration Options.
const size_t _Thread_Maximum_TLS_size
If this constant is greater than zero, then it defines the maximum thread-local storage size...
const size_t _Thread_Control_add_on_count
Thread control add-on count.
const Thread_Control_add_on _Thread_Control_add_ons[]
Thread control add-ons.
Evaluate User Extensions Configuration Options.
Scheduler node specialization for SMP schedulers.
#define CONFIGURE_MAXIMUM_THREAD_NAME_SIZE
This configuration option is an integer define.
Scheduler node specialization for Deterministic Priority schedulers.
#define rtems_resource_maximum_per_allocation(_resource)
Returns the maximum number per allocation of a resource number.
struct Thread_queue_Configured_heads Thread_queue_Configured_heads
The configured thread queue heads.
#define CONFIGURE_MINIMUM_POSIX_THREAD_STACK_SIZE
This configuration option is an integer define.
const size_t _Scheduler_Node_size
The size of a scheduler node.
#define RTEMS_ARRAY_SIZE(_array)
Returns the element count of the specified array.
const size_t _Thread_queue_Heads_size
Size of the thread queue heads of a particular application.
Scheduler node for per-thread data.
#define CONFIGURE_MAXIMUM_POSIX_THREADS
This configuration option is an integer define.
#define CONFIGURE_MAXIMUM_THREAD_LOCAL_STORAGE_SIZE
This configuration option is an integer define.
Constants and Structures Related with the Thread Control Block.
struct Thread_Configured_control Thread_Configured_control
The configured thread control block.
const size_t _Thread_Initial_thread_count
Count of configured threads.
Evaluate Block Device Cache Configuration Options.
const size_t _Thread_Maximum_name_size
Maximum size of a thread name in characters (including the terminating '\0' character).
Classic Tasks Manager Data Structures.