A driver may be loaded from any CFM container (in memory, files, or resources) as well as from a device's driver property in the Name Registry. The following services are provided for this purpose.
The only circumstance in which FindDriversForDevice or GetDriverForDevice is required is when there is a device node in the device tree that does not have an associated driver. One instance when this might happen is if a PCI card is entered in the device tree after system startup. FindDriversForDevice does not create a CFM connection for the driver it finds; this service is useful if you want to browse potential drivers for a device without loading them. GetDriverForDevice finds the driver and creates a CFM connection for it.
The successful load of a driver yields the following results:
If the driver has a CFM initialization routine, it will be executed. The initialization routine should return noErr to indicate a successful load. Note that multiple drivers may be loaded in order to determine the best device-to-driver match. Therefore, a driver's CFM initialization routine should not allocate resources that cannot be released in its termination routine.
The services listed above do not affect the Device Manager's unit table. They are discussed in the next sections.
Holding down the Shift, Command, N, and D keys simultaneously during Mac OS startup disables the loading of file-based drivers.