diff options
author | dwmalone <dwmalone@FreeBSD.org> | 2002-04-29 09:15:38 +0000 |
---|---|---|
committer | dwmalone <dwmalone@FreeBSD.org> | 2002-04-29 09:15:38 +0000 |
commit | 2eb82b93ad637b0d0525d53112535fe89053281c (patch) | |
tree | 3fb1b802694c9d8db9c3c535a1a8b529363f88f6 /sys/kern/subr_prf.c | |
parent | dafd57693bd94b06b4a40b4b56ac73814e22a01f (diff) | |
download | FreeBSD-src-2eb82b93ad637b0d0525d53112535fe89053281c.zip FreeBSD-src-2eb82b93ad637b0d0525d53112535fe89053281c.tar.gz |
Add a sysctl which disables the logging of console output.
Approved by: phk
MFC after: 2 weeks
Diffstat (limited to 'sys/kern/subr_prf.c')
-rw-r--r-- | sys/kern/subr_prf.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/kern/subr_prf.c b/sys/kern/subr_prf.c index d1c42a6..a063e4b 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); |