From 03f0dd1112df772ac1ec37008453bb6415833745 Mon Sep 17 00:00:00 2001 From: Nuno Antunes Date: Wed, 22 Aug 2012 07:47:11 +0100 Subject: [PATCH] sleep.9: Catch up with spin_{,un}lock_wr() -> spin_{,un}lock() rename of 2 years ago. * Accordingly rename function names in the ssleep() implementation example. * We have only exclusive spinlocks, remove the "(write)" reference which was implicitly suggesting that we have another kind. * While here, uncapitalize first letter of function a name. --- share/man/man9/sleep.9 | 11 ++++++----- 1 files changed, 6 insertions(+), 5 deletions(-) diff --git a/share/man/man9/sleep.9 b/share/man/man9/sleep.9 index 4580651..a07f8ce 100644 --- a/share/man/man9/sleep.9 +++ b/share/man/man9/sleep.9 @@ -143,8 +143,9 @@ contains the flag, signals are checked before and after sleeping, else signals are ignored. .Pp -.Fn Tsleep_interlock -is similar to +The +.Fn tsleep_interlock +function is similar to .Fn tsleep , in that it queues a thread on a sleep queue, but it does not actually put the thread to sleep. @@ -161,10 +162,10 @@ tsleep(..., PINTERLOCK) For example, to implement .Fn ssleep : .Bd -literal -spin_lock_wr(&important_lock); +spin_lock(&important_lock); if (important_condition == 0) { tsleep_interlock(ident, flags); - spin_unlock_wr(&important_lock); + spin_unlock(&important_lock); tsleep(..., PINTERLOCK); } .Ed @@ -173,7 +174,7 @@ The .Fn ssleep function works like .Fn tsleep -while at the same time releasing the exclusive (write) spinlock +while at the same time releasing the exclusive spinlock .Fa spin before sleeping and reacquiring it before .Fn ssleep -- 1.7.7.2