From owner-freebsd-hackers Sat Nov 30 15:43:35 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0C09137B401 for ; Sat, 30 Nov 2002 15:43:34 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 812A143E88 for ; Sat, 30 Nov 2002 15:43:33 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (fledge.pr.watson.org [192.0.2.3]) by fledge.watson.org (8.12.6/8.12.5) with SMTP id gAUNhSBF040745; Sat, 30 Nov 2002 18:43:29 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Sat, 30 Nov 2002 18:43:28 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: Yury Tarasievich Cc: freebsd-hackers@freebsd.org Subject: Re: documentation on kernel locks, mutexes? In-Reply-To: <20021125100013.GA3937@deptty.in.grsu.by> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, 25 Nov 2002, Yury Tarasievich wrote: > I need to port some driver from linux to freebsd and, somehow, I can't > find documentation on kernel locks and mutexes. There are no man pages, > links from handbook are broken, and search on freebsd site gives nothing > (besides the handbook itself). On 5.0-CURRENT, the following man pages may be of use to you: SMPng primitives (prefered for new code): mutex(9) Kernel synchronization primitives mtx_pool(9) Mutex pool routines condvar(9) Kernel condition variable sx(9) Kernel shared/exclusive lock sema(9) Kernel counting semaphores msleep(9) Wait for events Old-style BSD locking primitives: lockmgr(9) Lockmgr family of functions I believe these man pages may also be accessible via the FreeBSD web page. Also: http://www.freebsd.org/doc/en_US.ISO8859-1/books/developers-handbook/locking.html A chapter from the Developer's Handbook on kernel locking. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Network Associates Laboratories To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message