Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/share/man/man9 semantics of splclock() were changed, and spl...



details:   https://anonhg.NetBSD.org/src/rev/df73b39d6bc7
branches:  trunk
changeset: 484168:df73b39d6bc7
user:      soda <soda%NetBSD.org@localhost>
date:      Mon Mar 27 09:36:29 2000 +0000

description:
semantics of splclock() were changed, and spllowersoftclock() was introduced
on the following commit (thanks Frank van der Linden, Steve Woodford
and Alistair G. Crooks for english correction of HISTORY section):

date: 1999/08/05 18:08:10;  author: thorpej;  state: Exp;  lines: +3 -2

Change the semantics of splsoftclock() to be like other spl*() functions,
that is priority is rasied.  Add a new spllowersoftclock() to provide the
atomic drop-to-softclock semantics that the old splsoftclock() provided,
and update calls accordingly.

This fixes a problem with using the "rnd" pseudo-device from within
interrupt context to extract random data (e.g. from within the softnet
interrupt) where doing so would incorrectly unblock interrupts (causing
all sorts of lossage).

diffstat:

 share/man/man9/spl.9 |  25 ++++++++++++++++++++++---
 1 files changed, 22 insertions(+), 3 deletions(-)

diffs (60 lines):

diff -r 2996c2ace93b -r df73b39d6bc7 share/man/man9/spl.9
--- a/share/man/man9/spl.9      Mon Mar 27 09:33:22 2000 +0000
+++ b/share/man/man9/spl.9      Mon Mar 27 09:36:29 2000 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: spl.9,v 1.5 1999/03/16 00:40:48 garbled Exp $
+.\"    $NetBSD: spl.9,v 1.6 2000/03/27 09:36:29 soda Exp $
 .\"
 .\" Copyright (c) 1997 Michael Long.
 .\" Copyright (c) 1997 Jonathan Stone.
@@ -36,6 +36,7 @@
 .Nm splclock ,
 .Nm splhigh ,
 .Nm splimp ,
+.Nm spllowersoftclock ,
 .Nm splnet ,
 .Nm splsched ,
 .Nm splserial ,
@@ -73,6 +74,8 @@
 .Ft int
 .Fn splsoftclock void
 .Ft int
+.Fn spllowersoftclock void
+.Ft int
 .Fn spl0 void
 .Ft void
 .Fn splx "int s"
@@ -144,11 +147,13 @@
 blocks hard interrupts from disks and other mass-storage devices.
 .It Fn splsoftnet
 blocks soft network interrupts.
+.It Fn splsoftclock
+blocks soft clock interrupts.
 .El
 .Pp
 Two functions lower the system priority level.  They are:
-.Bl -tag -width splsoftclockXX
-.It Fn splsoftclock
+.Bl -tag -width spllowersoftclockXX
+.It Fn spllowersoftclock
 unblocks all interrupts but the soft clock interrupt.
 .It Fn spl0
 unblocks all interrupts.
@@ -161,3 +166,17 @@
 which must be a value previously returned by one of the other
 .Nm
 functions.
+.Pp
+.Sh HISTORY
+.Pp
+Originally,
+.Fn splsoftclock
+lowered the system priority level.
+During the
+.Nx 1.5
+development cycle,
+.Fn spllowersoftclock
+was introduced and the semantics of
+.Fn splsoftclock
+were changed.
+.Pp



Home | Main Index | Thread Index | Old Index