Print this page
5513 KM_NORMALPRI should be documented in kmem_alloc(9f) and kmem_cache_create(9f) man pages
14465 Present KM_NOSLEEP_LAZY as documented interface
Change-Id: I002ec28ddf390650f1fcba1ca94f6abfdb241439

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/os/vm_pageout.c
          +++ new/usr/src/uts/common/os/vm_pageout.c
↓ open down ↓ 125 lines elided ↑ open up ↑
 126  126   *   v Various parts of the kernel use minfree to signal the need for
 127  127   *   | more aggressive reclamation of memory, and sched() is more
 128  128   *   | aggressive at swapping processes out.
 129  129   *   |
 130  130   *   | If free memory falls below throttlefree, page_create_va() will
 131  131   *   | use page_create_throttle() to begin holding most requests for
 132  132   *   | new pages while pageout and reaping free up memory.  Sleeping
 133  133   *   v allocations (e.g., KM_SLEEP) are held here while we wait for
 134  134   *   | more memory.  Non-sleeping allocations are generally allowed to
 135  135   *   | proceed, unless their priority is explicitly lowered with
 136      - *   | KM_NORMALPRI.
      136 + *   | KM_NORMALPRI (Note: KM_NOSLEEP_LAZY == (KM_NOSLEEP | KM_NORMALPRI).).
 137  137   *   |
 138  138   *   +------- pageout_reserve (3/4 of throttlefree, 0.44% of physmem, min. 4MB)
 139  139   *   |
 140  140   *   | When we hit throttlefree, the situation is already dire.  The
 141  141   *   v system is generally paging out memory and swapping out entire
 142  142   *   | processes in order to free up memory for continued operation.
 143  143   *   |
 144  144   *   | Unfortunately, evicting memory to disk generally requires short
 145  145   *   | term use of additional memory; e.g., allocation of buffers for
 146  146   *   | storage drivers, updating maps of free and used blocks, etc.
↓ open down ↓ 1319 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX