root/include/vxworks.h

/* [<][>][^][v][top][bottom][index][help] */
   1 #ifndef _VXWORKS_
   2 #define _VXWORKS_
   3 /******************************************************************************/
   4 /**             VxWorks 5.5, kernel WIND version 2.6                         **/
   5 /**             Internal VxWorks kernel data types and constants             **/
   6 /******************************************************************************/
   7 #define TASK_STATE_READY    0
   8 #define TASK_STATE_SUSPEND  1
   9 #define TASK_STATE_PENDING  2
  10 #define TASK_STATE_DELAY    4
  11 #define TASK_STATE_DEAD     8
  12 /******************************************************************************/
  13 // Task context
  14 struct context_t
  15 {
  16     unsigned int r[13];
  17     unsigned int sp;
  18     unsigned int lr;
  19     unsigned int pc;
  20     unsigned int cpsr;
  21 };
  22 typedef struct context_t context_t;
  23 /******************************************************************************/
  24 // Task control block
  25 struct task_t {
  26     unsigned int    unknown1[13];
  27     char            *name;
  28     unsigned int    options;
  29     unsigned int    state;
  30     unsigned int    priority;
  31     unsigned int    unknown2[12];
  32     void            *entry;
  33     void            *stack_base;
  34     void            *stack_limit;
  35     void            *stack_end;
  36     unsigned int    error_num;
  37     unsigned int    exit_code;
  38     unsigned int    unknown3[7];
  39     void            *task_std_fp[3];    // pointers to FILE structures
  40     unsigned int    task_std_fd[3];     // std file descriptors
  41     unsigned int    unknown4[24];
  42     context_t context;
  43     unsigned int    unknown5[11];
  44 };
  45 typedef struct task_t task_t;
  46 /******************************************************************************/
  47 
  48 #endif

/* [<][>][^][v][top][bottom][index][help] */