The [HKEY_LOCAL_MACHINE\Drivers\Builtin] key contains subkeys for device drivers that the Device Manager should load when the system is turned on. Each subkey is named after the device driver and contains values described in the following table. Additional values can be stored for purposes specific to the device driver.
Typically, installable device drivers will not use anything within the [Drivers\Builtin] key. However, if it is important for your driver to be loaded when the Windows CE platform undergoes a warm reboot, the driver's installation routine can install a key within the [Drivers\Builtin] key. Be cautious, however; you should not modify any existing keys within this portion of the registry. It is also good to recommend that users do a full backup of the data on their Windows CE platform in the event that changes to keys within this portion of the registry cause their Windows CE platform to become unusable.
Value name | Value Type | Description |
---|---|---|
Dll | REG_SZ | This required entry specifies the filename for an driver DLL the Device Manager is to load. |
Entry | REG_SZ | The Entry value, if it exists, names an entry point to the DLL. The Device Manager loads the DLL and calls the specified entry point, with the driver's registry path as a parameter. When a driver is invoked in this manner, the driver is responsible for calling RegisterDevice on its own, and will not be tracked by the Device Manager. RegisterDevice calls LoadLibrary to load the DLL, so when the DLLs entry point returns, the Device Manager will call FreeLibrary to free the instance that it previously loaded. The function named in the Entry value must follow the prototype specified for PFN_DEV_ENTRY: DWORD (*PFN_DEV_ENTRY)(LPTSTR); where the LPSTR parameter is the registry path of the device's key. |
Keep | REG_SZ | The Keep value works in conjunction with the Entry value; if you have the Keep value, you must also have the Entry value. The existence of this value causes the Device Manager to not call FreeLibrary after the entry point specified in the Entry value returns. This behavior should only be used by DLLs which are loaded by the Device Manager at boot time but which are not actually device drivers. |
Order | DWORD | Specifies the load order for the built-in driver. If two drivers have the same load order value, they load in the order they occur in the registry. This entry is useful when one driver must load subsequent to another. This value is required for non-PC Card devices, ignored when loading PC Card drivers. |
Prefix | REG_SZ | This required value specifies the device driver's device filename prefix. It is a three character identifier, such as "COM". |
The following example shows the contents under the Builtin key for the standard serial port driver:
HKEY_LOCAL_MACHINE
[Drivers]
[BuiltIn]
[Serial]
SZ: Dll = Serial.DLL
DWORD: Order = 0x00000000 (0)
SZ: Prefix = COM
hex: DevConfig = 10 00 00 00 02 00 00 00 10 01 00 00 00 4b 00
DWORD: DeviceArrayIndex = 0x00000000 (0)
DWORD: DeviceType = 0x00000000 (0)
SZ: FriendlyName = Serial Cable on COM1:
SZ: Tsp = Unimodem.dll