1: /*
   2:  * Resource Allocation Maps.
   3:  *
   4:  * Associated routines manage allocation of an address space using
   5:  * an array of segment descriptors.
   6:  *
   7:  * Malloc and mfree allocate and free the resource described
   8:  * by the resource map.  If the resource map becomes too fragmented
   9:  * to be described in the available space, then some of the resource
  10:  * is discarded.  This may lead to critical shortages,
  11:  * but is better than not checking (as the previous versions of
  12:  * these routines did) or giving up and calling panic().
  13:  *
  14:  * N.B.: The address 0 in the resource address space is not available
  15:  * as it is used internally by the resource map routines.
  16:  */
  17: struct map {
  18:     struct  mapent *m_map;      /* start of the map */
  19:     struct  mapent *m_limit;    /* address of last slot in map */
  20:     char    *m_name;        /* name of resource */
  21: /* we use m_name when the map overflows, in warning messages */
  22: };
  23: struct mapent
  24: {
  25:     size_t  m_size;     /* size of this segment of the map */
  26:     memaddr m_addr;     /* resource-space addr of start of segment */
  27: };
  28: 
  29: 
  30: #ifdef  KERNEL
  31: extern  struct  map coremap[1]; /* space for core allocation */
  32: extern  struct  map swapmap[1]; /* space for swap allocation */
  33: #ifdef  UNIBUS_MAP
  34: extern  struct  map ub_map[1];  /* space for UNIBUS allocation */
  35: #endif
  36: #endif

Defined struct's

map defined in line 17; used 24 times
mapent defined in line 23; used 22 times

Usage of this include

Last modified: 1983-03-14
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 767
Valid CSS Valid XHTML 1.0 Strict