1 /* BEGIN INCLUDE FILE: cat.h */
 2 
 3 /* HISTORY COMMENTS:
 4   1) change(86-06-15,Westcott), approve(87-07-13,MCR7580),
 5      audit(87-07-13,Leskiw), install(87-08-07,MR12.1-1072):
 6      Created.
 7   2) change(86-09-04,Flegel), approve(87-07-13,MCR7580),
 8      audit(87-07-13,Leskiw), install(87-08-07,MR12.1-1072):
 9      Changed sleep time to int (long is too compiler dependent)
10                                                    END HISTORY COMMENTS */
11 
12 
13 /* FUNCTION:
14 
15 Defines the structures of the local and remote capability address tables.
16 Equivalent include file cat.mac
17 */
18 
19 #ifndef CAPABILITY_NAME_LENGTH
20 #include "ws.h"
21 #endif
22 
23 #ifndef MCB_DEFINED
24 #include "ws_mcb.h"
25 #endif
26 
27 #define RESET_BIT     01               /* Reset state of application */
28 #define SUSPENDED_BIT 02               /* Suspended state ... */
29 #define SLEEPING_BIT  04               /* Sleeping state ... */
30 #define WAITING_BIT   010              /* Waiting state ... */
31 #define NULL_BIT      020              /* No application entry */
32 
33 /* Remote CAT table structure element */
34 
35 typedef struct remote_cat_struct {
36     char major_capability;                        /* CAT index of capability  */
37     char system_id;                               /* System id field          */
38     char capability_name[CAPABILITY_NAME_LENGTH]; /* Name of capability       */
39     char flags;                                   /* State of capability      */
40 } remote_cat;
41 
42 /* Local CAT table structure element */
43 
44 typedef struct local_cat_struct {
45     struct local_cat_struct *next_cat;  /* Next capability sleeping         */
46     char  flags;                        /* State of capability              */
47     char  pad;                          /* to avoid alignment problems      */
48     long  sleep_time;                   /* Awakening time of capability     */
49     struct SREGS sregs;                 /* Capabilities segment registers   */
50     union REGS  regs;                   /* Capabilities registers           */
51     short bpreg;                        /* BasePtr register                 */
52     short spreg;                        /* StackPtr register                */
53     int   (*ws_entry)();                /* Entry point of capability action */
54     short waitreg;                      /* Wait register                    */
55     mcb   *mcb_ptr;                     /* MCB of capability                */
56 } local_cat;
57 
58 /* END INCLUDE FILE: cat.h */