From owner-p4-projects Wed Mar 20 7:45:54 2002 Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9133D37B417; Wed, 20 Mar 2002 07:45:49 -0800 (PST) Delivered-To: perforce@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id C71F137B416 for ; Wed, 20 Mar 2002 07:45:48 -0800 (PST) Received: (from perforce@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g2KFjm186010 for perforce@freebsd.org; Wed, 20 Mar 2002 07:45:48 -0800 (PST) (envelope-from bb+lists.freebsd.perforce@cyrus.watson.org) Date: Wed, 20 Mar 2002 07:45:48 -0800 (PST) Message-Id: <200203201545.g2KFjm186010@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: perforce set sender to bb+lists.freebsd.perforce@cyrus.watson.org using -f From: Robert Watson Subject: PERFORCE change 8055 for review To: Perforce Change Reviews Sender: owner-p4-projects@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG http://people.freebsd.org/~peter/p4db/chv.cgi?CH=8055 Change 8055 by rwatson@rwatson_tislabs on 2002/03/20 07:45:41 Add a description of the kernel module locking. Submitted by: arr Affected files ... ... //depot/projects/smpng/sys/design/article.sgml#18 edit Differences ... ==== //depot/projects/smpng/sys/design/article.sgml#18 (text+ko) ==== @@ -23,7 +23,7 @@ - $SMPng: //depot/projects/smpng/sys/design/article.sgml#17 $ + $SMPng: //depot/projects/smpng/sys/design/article.sgml#18 $ 2002 @@ -486,6 +486,23 @@ + Modules + + For the module subsystem there exists a single lock that is + used to protect the shared data. This lock is a shared/exclusive + (SX) lock and has a good chance of needing to be acquired (shared + or exclusively), there fore there are a few macros that have been + added to make access to the lock more easy. These macros can be + located in sys/module.h and are quite basic + in terms of usage. The main structures protected under this lock + are the module_t structures (when shared) + and the global modulelist_t structure, + modules. One should review the related source code in + kern/kern_module.c to further understand the + locking strategy. + + + Newbus Device Tree The newbus system will have one sx lock. Readers will To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message