USG_PG3/usr/source/head/systm.h
/*
* Random set of variables
* used by more than one
* routine.
*/
char canonb[CANBSIZ]; /* buffer for erase and kill (#@) */
struct map {
int m_size;
char *m_addr;
};
struct map coremap[CMAPSIZ]; /* space for core allocation */
struct map swapmap[SMAPSIZ]; /* space for swap allocation */
struct map ubmap[13]; /* Unibus Map allocation map */
int *rootdir; /* pointer to inode of root directory */
int *runq; /* head of linked list of running processes */
int cputype; /* type of cpu =40, 45, or 70 */
int lbolt; /* time of day in 60th not in time */
long time; /* time in sec from 1970 */
long tout; /* time of day of next sleep */
int *acctp; /* inode of accounting file */
struct {
char ac_comm[DIRSIZ]; /* Accounting command name */
char ac_flag; /* Accounting flag (unused) */
char ac_uid; /* Accounting user ID */
long ac_date; /* Accounting start time of command */
long ac_etime; /* Accounting elapsed time */
long ac_utime; /* Accounting user time */
long ac_stime; /* Accounting system time */
} acctbuf;
/*
* The callout structure is for
* a routine arranging
* to be called by the clock interrupt
* (clock.c) with a specified argument,
* in a specified amount of time.
* Used, for example, to time tab
* delays on typewriters.
*/
struct callo
{
int c_time; /* incremental time */
int c_arg; /* argument to routine */
int (*c_func)(); /* routine */
} callout[NCALL];
/*
* Mount structure.
* One allocated on every mount.
* Used to find the super block.
*/
struct mount
{
int m_dev; /* device mounted */
int *m_bufp; /* pointer to superblock */
int *m_inodp; /* pointer to mounted on inode */
} mount[NMOUNT];
/*
* Nblkdev is the number of entries
* (rows) in the block switch. It is
* set in binit/bio.c by making
* a pass over the switch.
* Used in bounds checking on major
* device numbers.
*/
int nblkdev;
/*
* Number of character switch entries.
* Set by cinit/tty.c
*/
int nchrdev;
int mpid; /* generic for unique process id's */
char runin; /* scheduling flag */
char runout; /* scheduling flag */
char runrun; /* scheduling flag */
char curpri; /* more scheduling */
int maxmem; /* actual max memory per process */
int *lks; /* pointer to clock device */
int rootdev; /* dev of root see conf.c */
int swapdev; /* dev of swap see conf.c */
int swplo; /* block number of swap space */
int nswap; /* size of swap space */
int updlock; /* lock for sync */
int rablock; /* block to be read ahead */
char regloc[]; /* locs. of saved user registers (trap.c) */
char msgbuf[MSGBUFS]; /* saved "printf" characters */
int blkacty; /* active block devices for error log */
int chracty; /* active character devices */
/*
* Instrumentation
*/
int dk_busy;
long dk_time[32];
long dk_numb[3];
long dk_wds[3];
long tk_nin;
long tk_nout;