Bosko Milekic d56368d779 Plug a race and a leak in UMA.
1) The race has to do with zone destruction.  From the zone destructor we
   would lock the zone, set the working set size to 0, then unlock the zone,
   drain it, and then free the structure.  Within the window following the
   working-set-size set to 0 and unlocking of the zone and the point where
   in zone_drain we re-acquire the zone lock, the uma timer routine could
   have fired off and changed the working set size to something non-zero,
   thereby potentially preventing us from completely freeing slabs before
   destroying the zone (and thus leaking them).

2) The leak has to do with zone destruction as well.  When destroying a
   zone we would take care to free all the buckets cached in the zone, but
   although we would drain the pcpu cache buckets, we would not free them.
   This resulted in leaking a couple of bucket structures (512 bytes each)
   per cpu on SMP during zone destruction.

While I'm here, also silence GCC warnings by turning uma_slab_alloc()
from inline to real function.  It's too big to be an inline.

Reviewed by: JeffR
2003-07-30 18:55:15 +00:00
..
2003-05-19 20:29:07 +00:00
2003-06-10 21:44:29 +00:00
2003-07-21 02:49:42 +00:00
2003-07-29 14:10:13 +00:00
2003-06-11 05:37:42 +00:00
2003-06-11 05:37:42 +00:00
2003-07-23 12:09:14 +00:00
2003-07-27 14:38:54 +00:00
2003-06-11 06:34:30 +00:00
2003-07-05 01:24:36 +00:00
2003-07-30 18:55:15 +00:00