summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_kobj.c
Commit message (Collapse)AuthorAgeFilesLines
* * Add multiple inheritance to kobj. Each class can have zero or more basedfr2003-10-161-33/+155
| | | | | | | | | | | | | | | | | | | | | | | | classes and if a method is not found in a given class, its base classes are searched (in the order they were declared). This search is recursive, i.e. a method may be define in a base class of a base class. * Change the kobj method lookup algorithm to one which is SMP-safe. This relies only on the constraint that an observer of a sequence of writes of pointer-sized values will see exactly one of those values, not a mixture of two or more values. This assumption holds for all processors which FreeBSD supports. * Add locking to kobj class initialisation. * Add a simpler form of 'inheritance' for devclasses. Each devclass can have a parent devclass. Searches for drivers continue up the chain of devclasses until either a matching driver is found or a devclass is reached which has no parent. This can allow, for instance, pci drivers to match cardbus devices (assuming that cardbus declares pci as its parent devclass). * Increment __FreeBSD_version. This preserves the driver API entirely except for one minor feature used by the ISA compatibility shims. A workaround for ISA compatibility will be committed separately. The kobj and newbus ABI has changed - all modules must be recompiled.
* add a read-only sysctl to display the number of entries in the fixed sizecg2003-08-141-5/+9
| | | | | | | | | kobj global method table; also kassert that the table has not overflowed when defining a new method. there are indications that the table is being overflowed in certain situations as we gain more kobj consumers- this will allow us to check whether kobj is at fault. symptoms would be incorrect methods being called.
* Use __FBSDID().obrien2003-06-111-2/+3
|
* Convert hit and miss counters to unsigned values. Surely negative valueskbyanc2002-06-101-4/+4
| | | | | | for either does not make sense. PR: (one small part of) 19720
* Convert more malloc+bzero to malloc+M_ZERO.dwmalone2000-12-081-2/+1
| | | | | Submitted by: josh@zipperup.org Submitted by: Robert Drehmel <robd@gmx.net>
* Add kobj_class_compile_static() to allow classes to be initialiseddfr2000-08-281-7/+27
| | | | | statically (i.e. without calling malloc). This allows kobj to be used very early in the boot sequence.
* * Move the driver_t::refs field to kobj_t to replace kobj_t::instances.dfr2000-05-011-3/+3
| | | | | * Back out a couple of workarounds for the confusion between kobj_t::instances and driver_t::refs.
* * Factor out the object system from new-bus so that it can be used bydfr2000-04-081-0/+197
non-device code. * Re-implement the method dispatch to improve efficiency. The new system takes about 40ns for a method dispatch on a 300Mhz PII which is only 10ns slower than a direct function call on the same hardware. This changes the new-bus ABI slightly so make sure you re-compile any driver modules which you use.
OpenPOWER on IntegriCloud