summaryrefslogtreecommitdiffstats
path: root/sys/sys/ktr.h
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2006-01-24 22:23:45 +0000
committerjhb <jhb@FreeBSD.org>2006-01-24 22:23:45 +0000
commit35abe809de4d150d519eb1b2324e391e28cbbb89 (patch)
tree3146fc9bed53c177ea70c8e7794c510c93f0889d /sys/sys/ktr.h
parent7ee7ea66a8deaa30672a52fb012843cd7e9f7bc2 (diff)
downloadFreeBSD-src-35abe809de4d150d519eb1b2324e391e28cbbb89.zip
FreeBSD-src-35abe809de4d150d519eb1b2324e391e28cbbb89.tar.gz
- Add a new KTR_SUBSYS in place of KTR_SPARE1 to serve as a subsystem
placeholder similar to KTR_DEV. Explain the use of KTR_DEV and KTR_SUBSYS in a comment as well. - Retire KTR_WITNESS and instead have KTR_WITNESS default to off but use KTR_SUBSYS if it is enabled.
Diffstat (limited to 'sys/sys/ktr.h')
-rw-r--r--sys/sys/ktr.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/sys/ktr.h b/sys/sys/ktr.h
index 4a996fc..3d6d98d 100644
--- a/sys/sys/ktr.h
+++ b/sys/sys/ktr.h
@@ -38,13 +38,18 @@
/*
* Trace classes
+ *
+ * Two of the trace classes (KTR_DEV and KTR_SUBSYS) are special in that
+ * they are really placeholders so that indvidual drivers and subsystems
+ * can map their internal tracing to the general class when they wish to
+ * have tracing enabled and map it to 0 when they don't.
*/
#define KTR_GEN 0x00000001 /* General (TR) */
#define KTR_NET 0x00000002 /* Network */
#define KTR_DEV 0x00000004 /* Device driver */
#define KTR_LOCK 0x00000008 /* MP locking */
#define KTR_SMP 0x00000010 /* MP general */
-#define KTR_SPARE1 0x00000020 /* Unused */
+#define KTR_SUBSYS 0x00000020 /* Subsystem. */
#define KTR_PMAP 0x00000040 /* Pmap tracing */
#define KTR_MALLOC 0x00000080 /* Malloc tracing */
#define KTR_TRAP 0x00000100 /* Trap processing */
@@ -60,7 +65,7 @@
#define KTR_VFS 0x00040000 /* VFS events */
#define KTR_VOP 0x00080000 /* Auto-generated vop events */
#define KTR_VM 0x00100000 /* The virtual memory system */
-#define KTR_WITNESS 0x00200000
+#define KTR_SPARE1 0x00200000 /* Unused */
#define KTR_RUNQ 0x00400000 /* Run queue */
#define KTR_CONTENTION 0x00800000 /* Lock contention */
#define KTR_UMA 0x01000000 /* UMA slab allocator */
OpenPOWER on IntegriCloud