freebsd-skq/lib/libmemstat
Robert Watson ca108fe268 UMA supports "secondary" zones, in which a second zone can be layered
on top of a primary zone, sharing the same allocation "keg".  When
reporting statistics for zones, do not report the free items in the
keg as part of the free items in the zone, or those free items will
be reported more than once: for the primary zone, and then any
secondary zones off the primary zone.  Separately record and maintain
a kegfree statistic, and export via memstat_get_kegfree(), which is
available for use if needed.  Since items free'd back to the keg are
not fully initialized, and hence may not actually be available (since
secondary zone ctor-time initialization can fail), this makes some
amount of sense.

This change corrects a bug made visible in the libmemstat(3)
modifications to netstat: mbufs freed back to the keg from the
packet zone would be counted twice, resulting in negative values
being printed in the mbuf free count.

Some further refinement of reporting relating to secondary zones may
still be required.

Reported by:	ssouhlal
MFC after:	3 days
2005-07-20 09:17:40 +00:00
..
libmemstat.3 UMA supports "secondary" zones, in which a second zone can be layered 2005-07-20 09:17:40 +00:00
Makefile
memstat_all.c
memstat_internal.h UMA supports "secondary" zones, in which a second zone can be layered 2005-07-20 09:17:40 +00:00
memstat_malloc.c Re-spell wronge less wrongly as wrong. 2005-07-15 10:13:50 +00:00
memstat_uma.c UMA supports "secondary" zones, in which a second zone can be layered 2005-07-20 09:17:40 +00:00
memstat.c UMA supports "secondary" zones, in which a second zone can be layered 2005-07-20 09:17:40 +00:00
memstat.h UMA supports "secondary" zones, in which a second zone can be layered 2005-07-20 09:17:40 +00:00