RTEMS
threadloadenv.c
Go to the documentation of this file.
1 
9 /*
10  * COPYRIGHT (c) 1989-1999.
11  * On-Line Applications Research Corporation (OAR).
12  *
13  * The license and distribution terms for this file may be
14  * found in the file LICENSE in this distribution or at
15  * http://www.rtems.org/license/LICENSE.
16  */
17 
18 #ifdef HAVE_CONFIG_H
19 #include "config.h"
20 #endif
21 
22 #include <rtems/score/threadimpl.h>
23 
25  Thread_Control *the_thread
26 )
27 {
28 #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
29  if ( the_thread->Start.fp_context ) {
30  the_thread->fp_context = the_thread->Start.fp_context;
31  _Context_Initialize_fp( &the_thread->fp_context );
32  }
33 #endif
34 
35  the_thread->is_preemptible = the_thread->Start.is_preemptible;
36  the_thread->budget_algorithm = the_thread->Start.budget_algorithm;
37  the_thread->budget_callout = the_thread->Start.budget_callout;
38 
40  &the_thread->Registers,
41  the_thread->Start.Initial_stack.area,
42  the_thread->Start.Initial_stack.size,
43  the_thread->Start.isr_level,
45  the_thread->is_fp,
46  the_thread->Start.tls_area
47  );
48 }
void _Thread_Load_environment(Thread_Control *the_thread)
Initializes enviroment for a thread.
Definition: threadloadenv.c:24
Thread_CPU_budget_algorithm_callout budget_callout
Definition: thread.h:816
bool is_preemptible
Definition: thread.h:795
Thread_Start_information Start
Definition: thread.h:825
#define _Context_Initialize_fp(_fp_area)
Initialize floating point context area.
Definition: context.h:129
Thread_CPU_budget_algorithms budget_algorithm
Definition: thread.h:814
size_t size
Definition: stack.h:55
#define _Context_Initialize(_the_context, _stack, _size, _isr, _entry, _is_fp, _tls_area)
Initialize context area.
Definition: context.h:76
Thread_CPU_budget_algorithm_callout budget_callout
Definition: thread.h:191
Stack_Control Initial_stack
Definition: thread.h:201
void _Thread_Handler(void)
Wrapper function for all threads.
Definition: threadhandler.c:76
Inlined Routines from the Thread Handler.
Thread_CPU_budget_algorithms budget_algorithm
Definition: thread.h:187
Context_Control Registers
Definition: thread.h:830
void * area
Definition: stack.h:57