aboutsummaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorBosko Milekic <bmilekic@FreeBSD.org>2003-06-20 22:18:38 +0000
committerBosko Milekic <bmilekic@FreeBSD.org>2003-06-20 22:18:38 +0000
commitb2b417bb414a9758d07cda62ec6c6d1afe097890 (patch)
tree84766036e556208e5515facef8f796dcb3ec03af /sys
parent795b332691b3d3c4d07f9e5e3f1884529bc78666 (diff)
Notes
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/subr_log.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/sys/kern/subr_log.c b/sys/kern/subr_log.c
index 229529acbe70..d721e2ead961 100644
--- a/sys/kern/subr_log.c
+++ b/sys/kern/subr_log.c
@@ -101,6 +101,10 @@ logopen(dev_t dev, int flags, int mode, struct thread *td)
log_open = 1;
callout_init(&logsoftc.sc_callout, 0);
fsetown(td->td_proc->p_pid, &logsoftc.sc_sigio); /* signal process only */
+ if (log_wakeups_per_second < 1) {
+ printf("syslog wakeup is less than one. Adjusting to 1.\n");
+ log_wakeups_per_second = 1;
+ }
callout_reset(&logsoftc.sc_callout, hz / log_wakeups_per_second,
logtimeout, NULL);
return (0);
@@ -183,6 +187,10 @@ logtimeout(void *arg)
if (!log_open)
return;
+ if (log_wakeups_per_second < 1) {
+ printf("syslog wakeup is less than one. Adjusting to 1.\n");
+ log_wakeups_per_second = 1;
+ }
if (msgbuftrigger == 0) {
callout_reset(&logsoftc.sc_callout,
hz / log_wakeups_per_second, logtimeout, NULL);