freebsd-skq/sys/security
Ed Schouten 29d4cb241b Don't enforce unique device minor number policy anymore.
Except for the case where we use the cloner library (clone_create() and
friends), there is no reason to enforce a unique device minor number
policy. There are various drivers in the source tree that allocate unr
pools and such to provide minor numbers, without using them themselves.

Because we still need to support unique device minor numbers for the
cloner library, introduce a new flag called D_NEEDMINOR. All cdevsw's
that are used in combination with the cloner library should be marked
with this flag to make the cloning work.

This means drivers can now freely use si_drv0 to store their own flags
and state, making it effectively the same as si_drv1 and si_drv2. We
still keep the minor() and dev2unit() routines around to make drivers
happy.

The NTFS code also used the minor number in its hash table. We should
not do this anymore. If the si_drv0 field would be changed, it would no
longer end up in the same list.

Approved by:	philip (mentor)
2008-06-11 18:55:19 +00:00
..
audit Don't enforce unique device minor number policy anymore. 2008-06-11 18:55:19 +00:00
mac Plug a memory leak which can occur when multiple MAC policies are loaded 2008-05-27 14:18:02 +00:00
mac_biba Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_bsdextended Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_ifoff Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_lomac Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_mls Properly return the error from mls_subject_privileged() in the ifnet 2008-01-28 10:20:18 +00:00
mac_none Consistently name functions for mac_<policy> as <policy>_whatever rather 2007-10-25 11:31:11 +00:00
mac_partition Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_portacl Consistently name functions for mac_<policy> as <policy>_whatever rather 2007-10-25 11:31:11 +00:00
mac_seeotheruids Resort TrustedBSD MAC Framework policy entry point implementations and 2007-10-29 13:33:06 +00:00
mac_stub Add a new file descriptor type for IPC shared memory objects and use it to 2008-01-08 21:58:16 +00:00
mac_test Add a new file descriptor type for IPC shared memory objects and use it to 2008-01-08 21:58:16 +00:00