Date: Wed, 8 Sep 2010 09:51:04 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r212315 - stable/8/share/man/man9 Message-ID: <201009080951.o889p4Rd004296@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Wed Sep 8 09:51:03 2010 New Revision: 212315 URL: http://svn.freebsd.org/changeset/base/212315 Log: MFC r212233: Document MAKEDEV_ETERNAL. Modified: stable/8/share/man/man9/make_dev.9 Directory Properties: stable/8/share/man/man9/ (props changed) Modified: stable/8/share/man/man9/make_dev.9 ============================================================================== --- stable/8/share/man/man9/make_dev.9 Wed Sep 8 08:03:08 2010 (r212314) +++ stable/8/share/man/man9/make_dev.9 Wed Sep 8 09:51:03 2010 (r212315) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd May 6, 2010 +.Dd September 5, 2010 .Dt MAKE_DEV 9 .Os .Sh NAME @@ -135,6 +135,7 @@ The following values are currently accep MAKEDEV_REF reference the created device MAKEDEV_NOWAIT do not sleep, may return NULL MAKEDEV_WAITOK allow the function to sleep to satisfy malloc +MAKEDEV_ETERNAL created device will be never destroyed .Ed .Pp The @@ -154,6 +155,18 @@ the device created is destroyed immediat drops his reference to cdev. .Pp The +.Dv MAKEDEV_ETERNAL +flag allows the kernel to not acquire some locks when translating system +calls into the cdevsw methods calls. +It is responsibility of the driver author to make sure that +.Fn destroy_dev +is never called on the returned cdev. +For the convenience, use the +.Dv MAKEDEV_ETERNAL_KLD +flag for the code that can be compiled into kernel or loaded +(and unloaded) as loadable module. +.Pp +The .Fn make_dev_cred function is equivalent to the call .Bd -literal -offset indent
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201009080951.o889p4Rd004296>