home *** CD-ROM | disk | FTP | other *** search
/ Piper's Pit BBS/FTP: ibm 0010 - 0019 / ibm0010-0019 / ibm0010.tar / ibm0010 / UNIX3862.ZIP / U386-06.ZIP / U386-6.TD0 / usr / include / sys / getpages.h < prev    next >
Encoding:
C/C++ Source or Header  |  1988-06-26  |  1.8 KB  |  72 lines

  1. /*    Copyright (c) 1984, 1986, 1987, 1988 AT&T    */
  2. /*      All Rights Reserved      */
  3.  
  4. /*    THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF AT&T    */
  5. /*    The copyright notice above does not evidence any       */
  6. /*    actual or intended publication of such source code.    */
  7.  
  8.  
  9. #ident    "@(#)head.sys:getpages.h    1.3"
  10.  
  11. /*    The following list is used to keep track of regions locked
  12. **    by getpages.
  13. */
  14.  
  15. typedef struct {
  16.     reg_t    *gpr_rgptr;    /* Pointer to the region.    */
  17.     int    gpr_count;    /* Number of pages from this    */
  18.                 /* region in spglist and     */
  19.                 /* fpglist.            */
  20. } gprgl_t;
  21.  
  22. extern gprgl_t    gprglst[];
  23. extern int    gprgndx;
  24.  
  25.  
  26. /*    The following structure is used to maintain a list of
  27.  *    pages to be stolen by getpages.
  28.  */
  29.  
  30. typedef struct {
  31.     pde_t    *gp_ptptr;    /* Ptr to page table entry.    */
  32.     gprgl_t    *gp_rlptr;    /* Ptr to region list entry.    */
  33. } pglst_t;
  34.  
  35. /*    The following define sets the maximum size chunk which
  36.  *    getpages can swap out at once.  The tuneable parameter
  37.  *    tune.t_maxsc can never be made larger than this value.
  38.  */
  39.  
  40. #define MAXSPGLST    100
  41.  
  42. /*    The following list is used to accumulate pages which we
  43. **    wish to steal but which must be written to swap first.
  44. */
  45.  
  46. extern pglst_t    spglst[];
  47. extern int    spglndx;
  48.  
  49. /*    The following list is used to accumulate pages which we
  50. **    wish to steal and which have a current copy on swap or
  51. **    a file and thus do not require any I/O to be done before
  52. **    they can be stolen.  The reason for accummulating them
  53. **    in a list instead of free each page as it is found is
  54. **    to reduce the number of ATB purges required.
  55. */
  56.  
  57. #define    MAXFPGLST    100
  58.  
  59. extern pglst_t    fpglst[];
  60. extern int    fpglndx;
  61.  
  62.  
  63. /*    The following word is used to lock the getpages tables
  64. **    described above so that vhand and sched can't both
  65. **    use them at the same time.
  66. */
  67.  
  68. extern int    pglstlock;
  69. extern int    pglstlk();
  70. extern int    pglstunlk();
  71.  
  72.