From 2406867f5b178a81c653b14524c0d5bad8189d2c Mon Sep 17 00:00:00 2001 From: Colin Percival Date: Sun, 20 Mar 2022 10:41:58 -0700 Subject: [PATCH] tslog: Add CTLFLAG_SKIP to sysctls The timestamp logs are quite large (often much larger than all the other sysctls combined) so it's unlikely anyone will want to have them displayed by `sysctl -a`. MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D34616 --- sys/kern/kern_tslog.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/kern/kern_tslog.c b/sys/kern/kern_tslog.c index 0e7ad3c9ff23..5eba7719880d 100644 --- a/sys/kern/kern_tslog.c +++ b/sys/kern/kern_tslog.c @@ -131,7 +131,8 @@ sysctl_debug_tslog(SYSCTL_HANDLER_ARGS) return (error); } -SYSCTL_PROC(_debug, OID_AUTO, tslog, CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE, +SYSCTL_PROC(_debug, OID_AUTO, tslog, + CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE|CTLFLAG_SKIP, 0, 0, sysctl_debug_tslog, "", "Dump recorded event timestamps"); MALLOC_DEFINE(M_TSLOGUSER, "tsloguser", "Strings used by userland tslog"); @@ -215,5 +216,6 @@ sysctl_debug_tslog_user(SYSCTL_HANDLER_ARGS) } SYSCTL_PROC(_debug, OID_AUTO, tslog_user, - CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE, 0, 0, sysctl_debug_tslog_user, + CTLTYPE_STRING|CTLFLAG_RD|CTLFLAG_MPSAFE|CTLFLAG_SKIP, + 0, 0, sysctl_debug_tslog_user, "", "Dump recorded userland event timestamps");