diff options
author | rwatson <rwatson@FreeBSD.org> | 2005-07-17 14:04:03 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2005-07-17 14:04:03 +0000 |
commit | 38dffb25ed020bf3bd3136f835904c8618803952 (patch) | |
tree | 9aa25437d2359619ec3fd7047a6c85ef26da0e20 /sys/sys/mbuf.h | |
parent | 82bb8e24de2d0f1c63aa8925bf17958bdbdf2153 (diff) | |
download | FreeBSD-src-38dffb25ed020bf3bd3136f835904c8618803952.zip FreeBSD-src-38dffb25ed020bf3bd3136f835904c8618803952.tar.gz |
Define four constants, MBUF_{,MEM,CLUSTER,PACKET,TAG}_MEM_NAME, which
are string names for their respective UMA zones and malloc types, and
are passed into uma_zcreate() and MALLOC_DEFINE(). Export them
outside of _KERNEL in mbuf.h so that netstat can reference them.
Change the names to improve consistency, with each zone/type
associated with the mbuf allocator being prefixed mbuf_.
MFC after: 1 week
Diffstat (limited to 'sys/sys/mbuf.h')
-rw-r--r-- | sys/sys/mbuf.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sys/sys/mbuf.h b/sys/sys/mbuf.h index c514e0f..9fb385c 100644 --- a/sys/sys/mbuf.h +++ b/sys/sys/mbuf.h @@ -287,6 +287,16 @@ struct mbstat { #define M_TRYWAIT M_WAITOK #define M_WAIT M_WAITOK +/* + * String names of mbuf-related UMA(9) and malloc(9) types. Exposed to + * !_KERNEL so that monitoring tools can look up the zones with + * libmemstat(3). + */ +#define MBUF_MEM_NAME "mbuf" +#define MBUF_CLUSTER_MEM_NAME "mbuf_cluster" +#define MBUF_PACKET_MEM_NAME "mbuf_packet" +#define MBUF_TAG_MEM_NAME "mbuf_tag" + #ifdef _KERNEL /*- * mbuf external reference count management macros. |