# 2.11BSD#431 - /usr/src/sys/h/text.h

##### Variables

    ntext             X

##### Macros

    XLOAD             X
    XLOCK             X
    XPAGI             X
    XTRC              X
    XUNUSED           X
    XWANT             X
    XWRIT             X
    X_DONTFREE        X
    X_FREECORE        X
    X_OLDSIZE         X
    _SYS_TEXT_H_      X

##### struct's

    text              X
    xstats            X

       1: /*
       2:  * Copyright (c) 1986 Regents of the University of California.
       3:  * All rights reserved.  The Berkeley software License Agreement
       4:  * specifies the terms and conditions for redistribution.
       5:  *
       6:  *	@(#)text.h	1.2 (2.11BSD GTE) 1/19/95
       7:  */
       8:
       9: #ifndef _SYS_TEXT_H_
      10: #define _SYS_TEXT_H_
      11:
      12: /*
      13:  * Text structure.			XXX REF COUNT should be short
      14:  * One allocated per pure
      15:  * procedure on swap device.
      16:  * Manipulated by text.c
      17:  */
      18: struct text
      19: {
      20:     struct  text *x_forw;   /* forward link in free list */
      21:     struct  text **x_back;  /* backward link in free list */
      22:     short   x_daddr;    /* segment's disk address */
      23:     short   x_caddr;    /* core address, if loaded */
      24:     size_t  x_size;     /* size (clicks) */
      25:     struct  inode *x_iptr;  /* inode of prototype */
      26:     u_char  x_count;    /* reference count */
      27:     u_char  x_ccount;   /* number of loaded references */
      28:     u_char  x_flag;     /* traced, written flags */
      29:     char    dummy;      /* room for one more */
      30: };
      31:
      32: #if defined(KERNEL) && !defined(SUPERVISOR)
      33: extern struct   text text[], *textNTEXT;
      34: int ntext;
      35: #endif
      36:
      37: #define XTRC    0x01        /* Text may be written, exclusive use */
      38: #define XWRIT   0x02        /* Text written into, must swap out */
      39: #define XLOAD   0x04        /* Currently being read from file */
      40: #define XLOCK   0x08        /* Being swapped in or out */
      41: #define XWANT   0x10        /* Wanted for swapping */
      42: #define XPAGI   0x20        /* Page in on demand from inode */
      43: #define XUNUSED 0x40        /* unused since swapped out for cache */
      44:
      45: /* arguments to xswap: */
      46: #define X_OLDSIZE   (-1)    /* the old size is the same as current */
      47: #define X_DONTFREE  0   /* save core image (for parent in newproc) */
      48: #define X_FREECORE  1   /* free core space after swap */
      49:
      50: /*
      51:  * Text table statistics
      52:  */
      53: struct xstats {
      54:     u_long  alloc;          /* calls to xalloc */
      55:     u_long  alloc_inuse;        /*	found in use/sticky */
      56:     u_long  alloc_cachehit;     /*	found in cache */
      57:     u_long  alloc_cacheflush;   /*	flushed cached text */
      58:     u_long  alloc_unused;       /*	flushed unused cached text */
      59:     u_long  free;           /* calls to xfree */
      60:     u_long  free_inuse;     /*	still in use/sticky */
      61:     u_long  free_cache;     /*	placed in cache */
      62:     u_long  free_cacheswap;     /*	swapped out to place in cache */
      63: };
      64: #endif /* _SYS_TEXT_H_ */

#### Defined variables

ntext defined in line 34; used 23 times

- in /usr/src/new/crash/crash.c line 275, 494(2)
- in /usr/src/sys/pdp/machdep2.c line 126
- in /usr/src/sys/sys/kern_sysctl.c line 225
- in /usr/src/sys/sys/vm_sched.c line 220
- in /usr/src/ucb/PORT/systat/swap.c line 64, 217, 225, 254-260(3)
- in /usr/src/usr.sbin/pstat/pstat.c line 301-311(6), 319-320(2), 327-333(3)

#### Defined struct's

text defined in line 18; used 88 times

- in line 20-21(4), 33(2)
- in /usr/src/sys/CURLY/param.c line 67(2), 147(2)
- in /usr/src/sys/GENERIC/param.c line 67(2), 147(2)
- in /usr/src/sys/QT/param.c line 67(2), 147(2)
- in /usr/src/sys/conf/param.c line 67(2), 147(2)
- in /usr/src/sys/h/sysctl.h line 199-200(4)
- in /usr/src/sys/sys/kern_mman.c line 218(2)
- in /usr/src/sys/sys/kern_sysctl.c line 790-791(4)
- in /usr/src/sys/sys/sys_process.c line 88(2)
- in /usr/src/sys/sys/vm_sched.c line 203(2)
- in /usr/src/sys/sys/vm_swap.c line 29(2)
- in /usr/src/sys/sys/vm_text.c line 65(2), 75(2), 89(2), 143(2), 254(2), 278(2), 288(2), 296(2), 308(2), 332(2), 345(2), 370(2)
- in /usr/src/ucb/PORT/systat/swap.c line 57(2), 225(4), 254-260(8)
- in /usr/src/usr.bin/fstat/fstat.c line 297(2)
- in /usr/src/usr.sbin/pstat/pstat.c line 300-307(8), 319(2)

xstats defined in line 53; used 6 times

- in /usr/src/sys/sys/vm_text.c line 67(2)
- in /usr/src/ucb/vmstat.c line 94(2), 508(2)

#### Defined macros

XLOAD defined in line 39; used 5 times

- in /usr/src/sys/sys/vm_swap.c line 55
- in /usr/src/sys/sys/vm_text.c line 198, 244, 257
- in /usr/src/usr.sbin/pstat/pstat.c line 340

XLOCK defined in line 40; used 8 times

- in /usr/src/sys/sys/vm_sched.c line 104
- in /usr/src/sys/sys/vm_text.c line 22-31(3), 108, 154, 198
- in /usr/src/usr.sbin/pstat/pstat.c line 341

XPAGI defined in line 42; used 2 times

- in /usr/src/ucb/PORT/systat/swap.c line 77
- in /usr/src/usr.sbin/pstat/pstat.c line 337

XTRC defined in line 37; used 4 times

- in /usr/src/sys/sys/kern_exec.c line 468
- in /usr/src/sys/sys/sys_process.c line 131
- in /usr/src/sys/sys/vm_text.c line 107
- in /usr/src/usr.sbin/pstat/pstat.c line 338

XUNUSED defined in line 43; used 4 times

- in /usr/src/sys/sys/vm_text.c line 115, 167, 193
- in /usr/src/usr.sbin/pstat/pstat.c line 343

XWANT defined in line 41; used 4 times

- in /usr/src/sys/sys/vm_text.c line 23, 29-31(2)
- in /usr/src/usr.sbin/pstat/pstat.c line 342

XWRIT defined in line 38; used 8 times

- in /usr/src/sys/sys/sys_process.c line 140
- in /usr/src/sys/sys/vm_text.c line 113, 243, 314-316(2), 377-379(2)
- in /usr/src/usr.sbin/pstat/pstat.c line 339

X_DONTFREE defined in line 47; used 1 times

- in /usr/src/sys/sys/kern_fork.c line 258

X_FREECORE defined in line 48; used 7 times

- in /usr/src/sys/sys/vm_proc.c line 91-93(2)
- in /usr/src/sys/sys/vm_sched.c line 149
- in /usr/src/sys/sys/vm_swap.c line 113-118(2), 143
- in /usr/src/sys/sys/vm_text.c line 267

X_OLDSIZE defined in line 46; used 10 times

- in /usr/src/sys/sys/kern_fork.c line 258(2)
- in /usr/src/sys/sys/vm_proc.c line 91-93(2)
- in /usr/src/sys/sys/vm_sched.c line 149(2)
- in /usr/src/sys/sys/vm_swap.c line 101-103(2)
- in /usr/src/sys/sys/vm_text.c line 267(2)

_SYS_TEXT_H_ defined in line 10; used 1 times

- in line 9

#### Usage of this include

text.h used 22 times

- in /usr/src/new/crash/crash.c line 96
- in /usr/src/sys/CURLY/param.c line 15
- in /usr/src/sys/GENERIC/param.c line 15
- in /usr/src/sys/QT/param.c line 15
- in /usr/src/sys/conf/param.c line 15
- in /usr/src/sys/h/sysctl.h line 50
- in /usr/src/sys/pdp/machdep2.c line 20
- in /usr/src/sys/sys/kern_exec.c line 24
- in /usr/src/sys/sys/kern_fork.c line 21
- in /usr/src/sys/sys/kern_mman.c line 15
- in /usr/src/sys/sys/kern_sig.c line 15
- in /usr/src/sys/sys/kern_sysctl.c line 52
- in /usr/src/sys/sys/sys_process.c line 18
- in /usr/src/sys/sys/ufs_inode.c line 19
- in /usr/src/sys/sys/vm_proc.c line 12
- in /usr/src/sys/sys/vm_sched.c line 12
- in /usr/src/sys/sys/vm_swap.c line 14
- in /usr/src/sys/sys/vm_text.c line 15
- in /usr/src/ucb/PORT/systat/swap.c line 15
- in /usr/src/ucb/vmstat.c line 29
- in /usr/src/usr.bin/fstat/fstat.c line 27
- in /usr/src/usr.sbin/pstat/pstat.c line 26

Last modified: 1995-01-21 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 603 |