]> rtime.felk.cvut.cz Git - rtems-pluggable-edf.git/blob - rtems-omk-template/edf/rbtree.h
Add 'tools' directory with precompiled i386 toolchain for 4.11
[rtems-pluggable-edf.git] / rtems-omk-template / edf / rbtree.h
1 #ifndef __RBTREE_h
2 #define __RBTREE_h
3
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7
8 #include "edf_types.h"
9         
10 // This struct will be embedded into the Thread_Control control 
11 // as scheduler_info 
12 typedef struct RBT_node_struct {
13         Deadline_Control abs_deadline;  
14         Deadline_Control rel_deadline;  
15         EDF_Node  *left;
16         EDF_Node  *right;
17         EDF_Node  *parent;
18         Node_Color       color;
19         EDF_Chain_Control *ready_chain;
20 } RBT_Node;
21
22 void _RBT_Insert(EDF_Chain_Control *chain,EDF_Node *node);
23 void  _RBT_Extract(EDF_Chain_Control *chain,EDF_Node *node);
24 EDF_Node* _RBT_Search(EDF_Chain_Control *chain,Deadline_Control absdeadline);
25 int _RBT_Has_only_one_node(EDF_Chain_Control *chain);
26
27
28 #ifdef __cplusplus
29 }
30 #endif
31
32 #endif /* __RBTREE_h */