Annotation of researchv9/sys.vax/h/lnode.h, revision 1.1

1.1     ! root        1: /*
        !             2: **     Structure for active shares.
        !             3: **
        !             4: **     Used by the kernel and by programs such as "init" and "login".
        !             5: */
        !             6: 
        !             7: typedef short  uid_t;
        !             8: 
        !             9: struct lnode
        !            10: {
        !            11:        uid_t           l_uid;          /* real uid for owner of this node */
        !            12:        u_short         l_flags;        /* (see below) */
        !            13:        u_short         l_shares;       /* allocated shares */
        !            14:        uid_t           l_group;        /* uid for this node's scheduling group */
        !            15:        float           l_usage;        /* decaying accumulated costs */
        !            16:        float           l_charge;       /* long term accumulated costs */
        !            17: };
        !            18: 
        !            19: /*
        !            20: **     Values of limits "flags".
        !            21: */
        !            22: 
        !            23: #define        ACTIVELNODE     001     /* this lnode is on active list */
        !            24: #define        LASTREF         002     /* set for L_DEADLIM if last reference to this lnode */
        !            25: #define        DEADGROUP       004     /* group account is dead */
        !            26: #define        CHNGDLIMITS     020     /* this lnode's limits have changed */
        !            27: #define        NOTSHARED       040     /* this lnode does not get a share of the m/c */
        !            28: 
        !            29: /*
        !            30: **     Kernel user share structure.
        !            31: */
        !            32: 
        !            33: typedef struct kern_lnode *    KL_p;
        !            34: 
        !            35: struct kern_lnode
        !            36: {
        !            37:        KL_p            kl_next;        /* next in active list */
        !            38:        KL_p            kl_prev;        /* prev in active list */
        !            39:        KL_p            kl_parent;      /* group parent */
        !            40:        KL_p            kl_gnext;       /* next in parent's group */
        !            41:        KL_p            kl_ghead;       /* start of this group */
        !            42:        struct lnode    kl;             /* user parameters */
        !            43:        float           kl_gshares;     /* total shares for this group */
        !            44:        float           kl_eshare;      /* effective share for this group */
        !            45:        float           kl_norms;       /* share**2 for this lnode */
        !            46:        float           kl_usage;       /* kl.l_usage / kl_norms */
        !            47:        float           kl_rate;        /* active process rate for this lnode */
        !            48:        float           kl_temp;        /* temporary for scheduler */
        !            49:        float           kl_spare;       /* <spare> */
        !            50:        u_long          kl_cost;        /* cost accumulating in current period */
        !            51:        u_long          kl_muse;        /* memory pages used */
        !            52:        u_short         kl_refcount;    /* processes attached to this lnode */
        !            53:        u_short         kl_children;    /* lnodes attached to this lnode */
        !            54: };
        !            55: 
        !            56: /*
        !            57: **     Limits system call defines.
        !            58: */
        !            59: 
        !            60: #define        L_MYLIM         0       /* get own lnode structure */
        !            61: #define        L_OTHLIM        1       /* get other user's lnode structure */
        !            62: #define        L_ALLLIM        2       /* get all active lnode structures */
        !            63: #define        L_SETLIM        3       /* set lnode for new user */
        !            64: #define        L_DEADLIM       4       /* get zombie and lnode structure of child */
        !            65: #define        L_CHNGLIM       5       /* change active lnode parameters */
        !            66: #define        L_DEADGROUP     6       /* get lnode structure for dead group */
        !            67: #define        L_GETCOSTS      7       /* get share constants */
        !            68: #define        L_SETCOSTS      8       /* set share constants */
        !            69: #define        L_MYKN          9       /* get own kern_lnode structure */
        !            70: #define        L_OTHKN         10      /* get other user's kern_lnode structure */
        !            71: #define        L_ALLKN         11      /* get all active kern_lnode structures */
        !            72: 
        !            73: /*
        !            74: **     Kernel lnode table.
        !            75: */
        !            76: 
        !            77: #ifdef KERNEL
        !            78: extern KL_p    lnodes;
        !            79: extern KL_p    lnodesMAXUSERS;
        !            80: extern KL_p    lastlnode;
        !            81: extern int     maxusers;
        !            82: 
        !            83: extern float   zerof;
        !            84: extern float   onef;
        !            85: extern float   twof;
        !            86: #endif KERNEL
        !            87: 
        !            88: #define        _LNODE_ 1

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.