From dbe620d321823d5fdcefd427c5efd8e3f5516db1 Mon Sep 17 00:00:00 2001 From: David Malone Date: Mon, 29 Apr 2002 09:15:38 +0000 Subject: Add a sysctl which disables the logging of console output. Approved by: phk MFC after: 2 weeks --- sys/kern/subr_prf.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/kern/subr_prf.c b/sys/kern/subr_prf.c index d1c42a657ef0..a063e4beac26 100644 --- a/sys/kern/subr_prf.c +++ b/sys/kern/subr_prf.c @@ -94,6 +94,10 @@ static int consintr = 1; /* Ok to handle console interrupts? */ static int msgbufmapped; /* Set when safe to use msgbuf */ int msgbuftrigger; +static int log_console_output = 1; +SYSCTL_INT(_kern, OID_AUTO, log_console_output, CTLFLAG_RW, + &log_console_output, 0, ""); + /* * Warn that a system table is full. */ @@ -242,6 +246,9 @@ log_console(struct uio *uio) char *consbuffer; int pri; + if (!log_console_output) + return; + pri = LOG_INFO | LOG_CONSOLE; muio = *uio; iovlen = uio->uio_iovcnt * sizeof (struct iovec); -- cgit v1.3