Added per-task variable data stucture (rtems_task_variable_t),

task_variables field to API extension, and two directives
(rtems_task_variable_add and rtems_task_variable_delete).
This commit is contained in:
Joel Sherrill
1999-11-12 14:52:36 +00:00
parent f477165695
commit 884b460d64
2 changed files with 72 additions and 8 deletions

View File

@@ -146,6 +146,16 @@ typedef struct {
unsigned32 argument; /* task argument */
} rtems_initialization_tasks_table;
/*
* Per task variable structure
*/
struct rtems_task_variable_t {
struct rtems_task_variable_t *next;
int *ptr;
int var;
};
/*
* This is the API specific information required by each thread for
* the RTEMS API to function correctly.
@@ -153,10 +163,11 @@ typedef struct {
typedef struct {
unsigned32 Notepads[ RTEMS_NUMBER_NOTEPADS ];
rtems_event_set pending_events;
rtems_event_set event_condition;
ASR_Information Signal;
unsigned32 Notepads[ RTEMS_NUMBER_NOTEPADS ];
rtems_event_set pending_events;
rtems_event_set event_condition;
ASR_Information Signal;
struct rtems_task_variable_t *task_variables;
} RTEMS_API_Control;
/*
@@ -405,6 +416,27 @@ rtems_status_code rtems_task_is_suspended(
Objects_Id id
);
/*
* rtems_task_variable_add
*
* This directive adds a per task variable.
*/
rtems_status_code rtems_task_variable_add(
rtems_id tid,
int *ptr
);
/*
* rtems_task_variable_delete
*
* This directive removes a per task variable.
*/
rtems_status_code rtems_task_variable_delete(
rtems_id tid,
int *ptr
);
/*
* _RTEMS_tasks_Initialize_user_tasks